Example #1
0
 public void Update(BaseProperty baseProperty)
 {
     foreach (Campaign item in campaigns)
     {
         if (baseProperty.Id == item.Id)
         {
             item.Name         = ((Campaign)baseProperty).Name;
             item.Discount     = ((Campaign)baseProperty).Discount;
             item.CampaignGame = ((Campaign)baseProperty).CampaignGame;
             break;
         }
     }
     Console.WriteLine("Campaign updated : " + baseProperty.Name);
 }
Example #2
0
 public void Update(BaseProperty baseProperty)
 {
     foreach (Game item in games)
     {
         if (baseProperty.Id == item.Id)
         {
             item.Name  = ((Game)baseProperty).Name;
             item.Price = ((Game)baseProperty).Price;
             item.Type  = ((Game)baseProperty).Type;
             break;
         }
     }
     Console.WriteLine("Game updated : " + baseProperty.Name);
 }
Example #3
0
 public void Delete(BaseProperty baseProperty)
 {
     campaigns.Remove((Campaign)baseProperty);
     Console.WriteLine("Campaign deleted : " + baseProperty.Name);
 }
Example #4
0
 public void Add(BaseProperty baseProperty)
 {
     campaigns.Add((Campaign)baseProperty);
     Console.WriteLine("Campaign added : " + baseProperty.Name);
 }
Example #5
0
 public void Delete(BaseProperty baseProperty)
 {
     games.Remove((Game)baseProperty);
     Console.WriteLine("Game deleted : " + baseProperty.Name);
 }
Example #6
0
 public void Add(BaseProperty baseProperty)
 {
     games.Add((Game)baseProperty);
     Console.WriteLine("Game added : " + baseProperty.Name);
 }