示例#1
0
 public static AgeDto createAgeDTO(String AgeId, String AgeDescription)
 {
     AgeDto age = new AgeDto();
     age.AgeId = AgeId;
     age.AgeDescription = AgeDescription;
     return age;
 }
示例#2
0
 public static AgeDto createAgeDTO(Age obj)
 {
     AgeDto age = new AgeDto();
     age.AgeId = obj.AgeId;
     age.AgeDescription = obj.AgeDescription;
     return age;
 }
示例#3
0
 public Boolean insertAge(AgeDto dto)
 {
     Age obj = Age.createAge(dto.AgeId, dto.AgeDescription);
     AgeManager mgr = new AgeManager();
     return mgr.insertAge(obj);
 }
示例#4
0
 public AgeDto selectAgeById(AgeDto dto)
 {
     AgeManager mgr = new AgeManager();
     Age obj = new Age();
     obj.AgeId = dto.AgeId;
     obj = mgr.selectAgeById(obj);
     if (obj != null)
     {
         return AgeDto.createAgeDTO(obj);
     }
     else
     {
         return null;
     }
 }