Esempio n. 1
0
 public Boolean insertAge(String AgeId, String AgeDescription)
 {
     Age obj = Age.createAge(AgeId, AgeDescription);
     AgeManager mgr = new AgeManager();
     return mgr.insertAge(obj);
 }
Esempio n. 2
0
    public AgeDto selectAgeById(String AgeId)
    {
        AgeManager mgr = new AgeManager();
        Age obj = new Age();
        obj.AgeId = AgeId;
        obj = mgr.selectAgeById(obj);

        if (obj != null)
        {
            return AgeDto.createAgeDTO(obj);
        }
        else
        {
            return null;
        }
    }
Esempio n. 3
0
    public List<AgeDto> selectAllAge()
    {
        AgeManager mgr = new AgeManager();
        List<Age> AgeList = mgr.selectAllAge();
        List<AgeDto> dtoList = new List<AgeDto>();

        foreach (Age age in AgeList)
        {
            dtoList.Add(AgeDto.createAgeDTO(age));
        }

        return dtoList;
    }
Esempio n. 4
0
 public Boolean insertAge(AgeDto dto)
 {
     Age obj = Age.createAge(dto.AgeId, dto.AgeDescription);
     AgeManager mgr = new AgeManager();
     return mgr.insertAge(obj);
 }