1 25 26 package org.infoglue.cms.entities.management.impl.simple; 27 28 import org.infoglue.cms.entities.kernel.BaseEntityVO; 29 import org.infoglue.cms.entities.management.Category; 30 import org.infoglue.cms.entities.management.CategoryVO; 31 32 public class CategoryImpl implements Category 33 { 34 private CategoryVO valueObject = new CategoryVO(); 35 36 public CategoryImpl() 37 {} 38 39 public CategoryImpl(Integer id) 40 { 41 setCategoryId(id); 42 } 43 44 public CategoryImpl(CategoryVO vo) 45 { 46 valueObject = (vo != null)? vo : new CategoryVO(); 47 } 48 49 public Integer getId() { return valueObject.getId(); } 50 public Object getIdAsObject() { return getId(); } 51 52 public Integer getCategoryId() { return valueObject.getCategoryId(); } 53 public void setCategoryId(Integer i){ valueObject.setCategoryId(i); } 54 55 public String getName() { return valueObject.getName(); } 56 public void setName(String s) { valueObject.setName(s); } 57 58 public String getDescription() { return valueObject.getDescription(); } 59 public void setDescription(String s){ valueObject.setDescription(s); } 60 61 public boolean isActive() { return valueObject.isActive(); } 62 public void setActive(boolean b) { valueObject.setActive(b); } 63 64 public Integer getParentId() { return valueObject.getParentId(); } 65 public void setParentId(Integer i) { valueObject.setParentId(i); } 66 67 public CategoryVO getValueObject() { return valueObject; } 68 public void setValueObject(CategoryVO vo) { valueObject = vo; } 69 70 public BaseEntityVO getVO() { return (BaseEntityVO) getValueObject(); } 71 public void setVO(BaseEntityVO vo) { setValueObject((CategoryVO) vo); } 72 73 public String toString() 74 { 75 return valueObject.toString(); 76 } 77 } 78 | Popular Tags |