예제 #1
0
        public bool UpdateBadge(int oldBadge, BadgesPOCOs newBadgeData)
        {
            BadgesPOCOs oldBadgeData = GetBadgesByKey(oldBadge);

            if (oldBadgeData == null)
            {
                return(false);
            }
            else
            {
                oldBadgeData.DoorAccess = newBadgeData.DoorAccess;
                oldBadgeData.BadgeID    = newBadgeData.BadgeID;

                return(true);
            }
        }
예제 #2
0
 public bool AddNewBadge(BadgesPOCOs newBadge)
 {
     Count++;
     _badgesDict.Add(Count, newBadge);
     return(true);
 }