001/** 002 * Copyright 2005-2016 The Kuali Foundation 003 * 004 * Licensed under the Educational Community License, Version 2.0 (the "License"); 005 * you may not use this file except in compliance with the License. 006 * You may obtain a copy of the License at 007 * 008 * http://www.opensource.org/licenses/ecl2.php 009 * 010 * Unless required by applicable law or agreed to in writing, software 011 * distributed under the License is distributed on an "AS IS" BASIS, 012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 013 * See the License for the specific language governing permissions and 014 * limitations under the License. 015 */ 016package org.kuali.rice.kim.impl.common.template; 017 018import javax.persistence.Column; 019import javax.persistence.Convert; 020import javax.persistence.MappedSuperclass; 021 022import org.kuali.rice.kim.api.common.template.TemplateContract; 023import org.kuali.rice.krad.bo.DataObjectBase; 024import org.kuali.rice.krad.bo.PersistableBusinessObjectBase; 025import org.kuali.rice.krad.data.jpa.converters.BooleanYNConverter; 026import org.kuali.rice.krad.data.provider.annotation.BusinessKey; 027 028@MappedSuperclass 029public abstract class TemplateBo extends PersistableBusinessObjectBase implements TemplateContract { 030 031 private static final long serialVersionUID = 1L; 032 033 @Column(name="NMSPC_CD",nullable=false) 034 @BusinessKey 035 protected String namespaceCode; 036 037 @Column(name="NM",nullable=false) 038 @BusinessKey 039 protected String name; 040 041 @Column(name="DESC_TXT", length=400) 042 protected String description; 043 044 @Column(name="KIM_TYP_ID") 045 protected String kimTypeId; 046 047 @Column(name="ACTV_IND") 048 @Convert(converter = BooleanYNConverter.class) 049 protected boolean active; 050 051 @Override 052 public String getNamespaceCode() { 053 return namespaceCode; 054 } 055 056 public void setNamespaceCode(String namespaceCode) { 057 this.namespaceCode = namespaceCode; 058 } 059 060 @Override 061 public String getName() { 062 return name; 063 } 064 065 public void setName(String name) { 066 this.name = name; 067 } 068 069 @Override 070 public String getDescription() { 071 return description; 072 } 073 074 public void setDescription(String description) { 075 this.description = description; 076 } 077 078 @Override 079 public String getKimTypeId() { 080 return kimTypeId; 081 } 082 083 public void setKimTypeId(String kimTypeId) { 084 this.kimTypeId = kimTypeId; 085 } 086 087 @Override 088 public boolean isActive() { 089 return active; 090 } 091 092 public void setActive(boolean active) { 093 this.active = active; 094 } 095}