private static void ColorAddTest() { ColorManager colorManager = new ColorManager(new EfColorDal()); colorManager.Add(new Color { Id = 4, ColorName = "Siyah" }); }
private static void ColorAdd() { ColorManager colorManager = new ColorManager(new EfColorDal()); colorManager.Add(new Color { ColorName = "Gri" }); }
private static void ColorAdded() { ColorManager colorManager = new ColorManager(new EfColorDal()); colorManager.Add(new Color { Id = 2, ColorName = "Beyaz" }); }
private static void ColorAddedTest() { ColorManager colorManager = new ColorManager(new EfColorDal()); colorManager.Add(new Color { ColorId = 7, ColorName = "Yeşil" }); }
private static void ColorTest() { ColorManager colorManager = new ColorManager(new EfColorDal()); colorManager.Add(new Color { ColorId = 33, ColorName = "Red" }); }
// ------------------------------- Case 5 : AddNewColor ---------------------------------------- private static void AddNewColor(ColorManager colorManager) { Color color1 = new Color(); Console.WriteLine("Color Name: "); color1.ColorName = Console.ReadLine(); colorManager.Add(color1); }
private static void ColorTest() { ColorManager colorManager = new ColorManager(new EfColorDal()); colorManager.Add(new Color { ColorName = "Siyah" }); colorManager.Add(new Color { ColorName = "Kırmızı" }); Console.WriteLine("---color---"); foreach (var color in colorManager.GetAll()) { Console.WriteLine(color.ColorId + " " + color.ColorName); } }
private protected static void AddColorTest() { ColorManager colorManager = new ColorManager(new EfColorDal()); colorManager.Add(new Color { ColorName = "Purple" }); }
// ************ Color ************ private static void AddColorTest(Color color) { ColorManager colorManager = new ColorManager(new EfColorDal()); var result = colorManager.Add(color); Console.WriteLine(result.Message); }
private static void AddColor() { ColorManager colorManager = new ColorManager(new EfColorDal()); colorManager.Add(new Color { Name = "Bulut Gri" }); }
private static void AddColor() { ColorManager colorManager = new ColorManager(new EfColorDal()); colorManager.Add(new Color { ColorId = "5", ColorName = "Kırmızı" }); }
private static void ColorManagerTest() { ColorManager colorManager = new ColorManager(new EfColorDal()); colorManager.Add(new Color() { ColorId = 1, ColorName = "Dark Gray" }); colorManager.Add(new Color() { ColorId = 2, ColorName = "Light Gray" }); colorManager.Add(new Color() { ColorId = 3, ColorName = "Black" }); }
private static void AddColor(string colorName) { ColorManager colorManager = new ColorManager(new EfColorDal()); colorManager.Add(new Color { Name = colorName }); }
private static void ColorAdd() { ColorManager colorManager = new ColorManager(new EfColorDal()); colorManager.Add(new Color { Name = "Orrange" }); }
private static void AddTest(ColorManager colorManager) { var result = colorManager.Add(new Color { ID = 4, ColorName = "Blue" }); Console.WriteLine(result.Message); }
static void Main(string[] args) { // ***** Car Class manager ****** CarManager car1 = new CarManager(new EfCarDal()); car1.Add(new Car { CarId = 30, BrandId = 20, ColorId = 10, ModelYear = new DateTime(2010, 2, 2), DailyPrice = 20000, Description = "test" }); foreach (var car in car1.GetAll()) { Console.WriteLine("Car ID : " + car.CarId); Console.WriteLine("BrandId : " + car.BrandId); Console.WriteLine("Color ID : " + car.ColorId); Console.WriteLine("Model year : " + car.ModelYear); Console.WriteLine("Daily Price : " + car.DailyPrice); Console.WriteLine("Description : " + car.Description); } foreach (var car in car1.GetAllByBrandId(5)) { Console.WriteLine("BrandId : " + car.BrandId); } foreach (var car in car1.GetByDailyPrice(20, 50)) { Console.WriteLine("Daily Price : " + car.DailyPrice); } // ***** Color Class manager ****** ColorManager color1 = new ColorManager(new EfColorDal()); color1.Add(new Color { ColorId = 88, ColorName = "Mavi" }); foreach (var color in color1.GetAll()) { Console.WriteLine("Color ID : " + color.ColorId); Console.WriteLine("Color Name : " + color.ColorName); } // ***** Brand Class manager ****** BrandManager brand1 = new BrandManager(new EfBrandDal()); brand1.Add(new Brand { BrandId = 50, BrandName = "Toyota" }); foreach (var brand in brand1.GetAll()) { Console.WriteLine("Brand ID : " + brand.BrandId); Console.WriteLine("Brand Name : " + brand.BrandName); } }
private static void RunColorManager() { ColorManager colorManager = new ColorManager(new EfColorDal()); int options = -1; while (options != 0) { Console.WriteLine("1)List All Color\n" + "2)Get Color By ID\n" + "3)Add Color\n" + "4)Delete Color\n" + "5)Update Color\n" + "0)Exit Menu" + ""); options = Convert.ToInt32(Console.ReadLine()); switch (options) { case 1: foreach (var color in colorManager.GetAll().Data) { Console.WriteLine("Color ID: {0} = {1}", color.ColorID, color.ColorName); } Console.WriteLine(colorManager.GetAll().Message); break; case 2: Console.WriteLine(colorManager.GetID(2).Data.ColorName); break; case 3: Console.WriteLine("-Enter Color Name-"); string addedColor = Console.ReadLine(); colorManager.Add(new Color { ColorName = addedColor }); break; case 4: Console.WriteLine("-Enter Color ID-"); int deletedColor = Convert.ToInt32(Console.ReadLine()); colorManager.Delete(new Color { ColorID = deletedColor }); break; case 5: Console.WriteLine("-Enter Color ID-"); int updatedColor = Convert.ToInt32(Console.ReadLine()); colorManager.Update(new Color { ColorID = updatedColor, ColorName = "Sarı" }); break; default: break; } } }
private static void ColorTest() { ColorManager colorManager = new ColorManager(new EfColorDal()); colorManager.Add(new Color { ColorName = "white" }); colorManager.Add(new Color { ColorName = "black" }); foreach (var color in colorManager.GetAll().Data) { System.Console.WriteLine(color.ColorName); } }
private static void AddColor() { ColorManager colorManager = new ColorManager(new EfColorDal()); var result = colorManager.Add(new Color { ColorName = "Kırmızı" }); Console.WriteLine(result.Message); }
private static void AddColor() { Color color = new Color(); color.ColorName = "Kahverengi"; ColorManager colorManager = new ColorManager(new EfColorDal()); colorManager.Add(color); }
private static void ColorAdd() { ColorManager colorManager = new ColorManager(new EfColorDal()); Color color = new Color(); color.ColorName = "Pembe"; colorManager.Add(color); ColorGetAll(); }
private static void ColorTest() { ColorManager colorManager = new ColorManager(new EfColorDal()); colorManager.Add(new Color { ColorId = 1, ColorName = "Siyah" }); colorManager.Add(new Color { ColorId = 2, ColorName = "Beyaz" }); colorManager.Delete(new Color { ColorId = 3, ColorName = "Kırmızı" }); foreach (var color in colorManager.GetAll()) { Console.WriteLine(color.ColorId + " " + color.ColorName); } }
private static void ColorTest() { ColorManager colorManager = new ColorManager(new EFColorDal()); var colorAdded = colorManager.Add(new Color { ColorName = "Red" }); Console.WriteLine(colorAdded.Message); }
public static void AddColor() { ColorManager colorManager = new ColorManager(new EfColorDal()); Color newColor = new Color(); Console.Write("Marka Giriniz:"); newColor.Name = Console.ReadLine(); colorManager.Add(newColor); }
private static void DeleteTest(ColorManager colorManagerEF) { colorManagerEF.Add(new Color { Id = 5, Name = "YanlışRenk" }); colorManagerEF.Delete(new Color { Id = 5, Name = "YanlışRenk" }); }
private static void AddToColor(ColorManager colorManager) { string colorName; Console.Write("\nEklemek istediğiniz yeni Renk Adı : "); colorName = Console.ReadLine(); var result = colorManager.Add(new Color { ColorName=colorName}); Console.WriteLine(result.Message); }
private static void ColorAdd() { ColorManager colorManager = new ColorManager(new EfColorDal()); Color color = new Color { ColorName = "Yeşlil", ColorId = 3 }; colorManager.Add(color); }
private void AddColor() { Color color = new Color(); Console.WriteLine("Name: "); color.Name = Console.ReadLine(); _colorManager.Add(color); Console.WriteLine("Color" + Messages.AddSingular); }
private static void RenkDeneme(ColorManager colorManager) { colorManager.Add(new Color() { ColorID = 1, ColorName = "Beyaz" }); colorManager.Add(new Color() { ColorID = 2, ColorName = "Siyah" }); colorManager.Add(new Color() { ColorID = 3, ColorName = "Kırmızı" }); colorManager.Add(new Color() { ColorID = 4, ColorName = "MAVİ" }); }
static void Main(string[] args) { //CarTest(); ColorManager colorManager = new ColorManager(new EfColorDal()); colorManager.Add(new Color { ColorName = "Turuncu" }); Console.WriteLine(colorManager.GetAll()); }