コード例 #1
0
        //DevTeam Update
        public bool UpdateDevTeam(int givenID, DevTeam newTeam)
        {
            DevTeam old = GetListBYID(givenID);

            if (old != null)
            {
                old.DevName       = newTeam.DevName;
                old.IsTeamLeader  = newTeam.IsTeamLeader;
                old.MembersNumber = newTeam.MembersNumber;
                old.TeamName      = old.TeamName;
                return(true);
            }
            else
            {
                return(false);
            }
        }
コード例 #2
0
        //DevTeam Delete
        public bool RemoveTeam(int id)
        {
            DevTeam devTeam = GetListBYID(id);

            if (devTeam == null)
            {
                return(false);
            }
            int initialCount = _devTeams.Count;

            _devTeams.Remove(devTeam);

            if (initialCount > _devTeams.Count)
            {
                return(true);
            }
            return(false);
        }
コード例 #3
0
 //DevTeam Read
 public void AddDevToTeam(Developer developer, DevTeam devTeam)
 {
     devTeam._Developers.Add(developer);
 }
コード例 #4
0
 //DevTeam Create
 public void AddDevTeamList(DevTeam team)
 {
     _devTeams.Add(team);
 }