static void Main(string[] args) { Player player1 = new Player(); player1.PlayerName = "Magnus"; player1.PlayerSurname = "Carlsen"; player1.TcNo = "245165496"; player1.PlayerBirthday = "30.11.1990"; Player player2 = new Player(); player2.PlayerName = "Hikaru"; player2.PlayerSurname = "Nakamura"; player2.TcNo = "996526512"; player2.PlayerBirthday = "9.12.1987"; E_Devlet eDevletPlayerInformation1 = new E_Devlet(); eDevletPlayerInformation1.E_devlet_Isim = "Magnus"; eDevletPlayerInformation1.E_devlet_Soyad = "Carlsen"; eDevletPlayerInformation1.E_devlet_TcNo = "245165496"; eDevletPlayerInformation1.E_devlet_Birthday = "30.11.1990"; Game game1 = new Game(); game1.GameName = "Cyberpunk"; game1.GamePrice = 249; Game game2 = new Game(); game2.GameName = "Age of Empires II"; game2.GamePrice = 31; Game game3 = new Game(); game1.GameName = "Assasin's Creed: Odyssey"; game1.GamePrice = 249; Game game4 = new Game(); game1.GameName = "SpiderMan: Miles Morales"; game1.GamePrice = 499; Verification verification = new Verification(); verification.PlayerControl(player1, eDevletPlayerInformation1); Console.WriteLine("------------------------------"); ICampaignServices campaignManager = new CampaignManager(); campaignManager.CampaignEntry(game1); campaignManager.DeleteCampaign(game1); campaignManager.UpdateCampaign(game1); Console.WriteLine("----------------------------"); IPlayerServices playerManager = new PlayerManager(); playerManager.NewPlayer(player1); playerManager.DeletePlayer(player1); playerManager.UpdatePlayer(player1); Console.WriteLine("-------------------------------"); GameSaleManager gameSaleManager = new GameSaleManager(); gameSaleManager.GameSale(player1, game2); Console.WriteLine("------------------------------"); Console.ReadLine(); }
static void Main(string[] args) { Player player1 = new Player(); player1.Id = 1; player1.FirstName = "Süleyman"; player1.LastName = "Demirel"; player1.BirthYear = 2000; player1.TcNo = "12345"; Player player2 = new Player(); player2.Id = 2; player2.FirstName = "Mert"; player2.LastName = "Demir"; player2.BirthYear = 2001; player2.TcNo = "4235"; Player playerControl = new E_Devlet(); playerControl.FirstName = "Süleyman"; playerControl.LastName = "Demirel"; playerControl.BirthYear = 2000; playerControl.TcNo = "12345"; Game game1 = new Game(); game1.Id = 5; game1.GameName = "Counter Strike Global Offansive"; game1.GameCategory = "War"; game1.Price = 30; Game game2 = new Game(); game2.Id = 6; game2.GameName = "League Of Legends"; game2.GameCategory = "War, Fight"; game2.Price = 10; PlayerManager playerManager = new PlayerManager(); if (player1.FirstName == playerControl.FirstName && player1.LastName == playerControl.LastName && player1.BirthYear == playerControl.BirthYear && player1.TcNo == playerControl.TcNo) { playerManager.Add(player1); playerManager.Delete(player1); playerManager.Update(player1); } else { Console.WriteLine("Error."); } GameManager gameManager = new GameManager(); gameManager.Add(game1, player1); gameManager.Delete(game2, player2); ICampaignService campaignService = new BlackFridayCampaign(); // new NewMemberCampaign campaignService.Add(game1); campaignService.Delete(game1); campaignService.Update(game1); Console.ReadLine(); }