예제 #1
0
        static void Main(string[] args)
        {
            GamerManager gamerManager = new GamerManager(new ValidationManager());

            gamerManager.Add(new Gamer {
                Id = 1, IdentityNumber = 12345, FirstName = "MEHMET YASİN", LastName = "ÇİRAK", BirthYear = 1996
            });
            gamerManager.Delete(new Gamer {
                Id = 1, IdentityNumber = 12345, FirstName = "MEHMET YASİN", LastName = "ÇİRAK", BirthYear = 1996
            });
            gamerManager.Update(new Gamer {
                Id = 1, IdentityNumber = 1234, FirstName = "MEHMET YASİN", LastName = "ÇİRAK", BirthYear = 1996
            });

            Gamer gamer1 = new Gamer();

            gamer1.Id             = 1;
            gamer1.IdentityNumber = 12345;
            gamer1.FirstName      = "MEHMET YASİN";
            gamer1.LastName       = "ÇİRAK";
            gamer1.BirthYear      = 1996;
            gamerManager.Add(gamer1);

            Games games1 = new Games();

            games1.Id        = 1;
            games1.GameName  = "Valorant";
            games1.GamePrice = 10.00;

            Campaigns campaigns1 = new Campaigns();

            campaigns1.Id          = 1;
            campaigns1.Name        = "Black Friday";
            campaigns1.Description = "Büyük İndirim";
            campaigns1.Price       = 0.75;

            OrderManager orderManager = new OrderManager();

            orderManager.Add(gamer1, campaigns1, games1);
        }
 public void Add(Gamer gamer, Campaigns campaigns, Games games)
 {
     Console.WriteLine(gamer.FirstName + " kişisine " + games.GameName + " adlı oyun " + games.GamePrice * campaigns.Price + " Tl ye satılmıştır.");
 }
 public void Delete(Campaigns campaigns)
 {
     Console.WriteLine("Kampanya silindi.");
 }
 public void Update(Campaigns campaigns)
 {
     Console.WriteLine("Kampanya güncellendi.");
 }
 public void Add(Campaigns campaigns)
 {
     Console.WriteLine("Kampanya eklendi.");
 }