public GSM(string phoneModel, string phoneManufacturer, decimal phonePrice, string phoneOwner, Battery myBattery, Display myDisplay) : this(phoneModel, phoneManufacturer, phonePrice) { this.OwnerName = phoneOwner; this.Battery = myBattery; this.Display = myDisplay; }
public GSM(string modelGSM, string manifactGSM) { this.Model = modelGSM; this.Manufacturer = manifactGSM; this.batteryCharacteristics = new Battery(); this.displayCharacteristics = new Display(); this.callHistory = new List<Call>(); }
public GSM(string manufacturer, string model, string owner = null, double price = 0, Battery battery = null, Display display = null) { this.manufacturer = manufacturer; this.model = model; this.owner = owner; this.price = price; this.battery = battery; this.display = display; }
public GSM(string modelGSM, string manifactGSM, decimal priceGSM, string ownerGSM, Battery batt, Display displ) : this(modelGSM, manifactGSM) { this.Price = priceGSM; this.Owner = ownerGSM; this.batteryCharacteristics = batt; this.displayCharacteristics = displ; this.callHistory = new List<Call>(); }
public GSM(string model, string manufacturer, double? price, string owner, Battery bat, Display disp) { this.model = model; this.manufacturer = manufacturer; this.price = price; this.owner = owner; this.phoneBat = bat; this.phoneDisp = disp; }
static void Main() { Thread.CurrentThread.CurrentCulture = CultureInfo.InvariantCulture; Battery myBattery = new Battery("Bateria"); Display myDisplay = new Display(); GSM myGSM = new GSM("Nokia","Nokia", 100.23M, "Pesho",myBattery,myDisplay); string myGSMinfo = myGSM.ToString(); Console.WriteLine(myGSMinfo); GSM mySecondGSM = GSM.IPhone4S; Console.WriteLine(mySecondGSM); GSMTest test = new GSMTest(); test.Create4GSMs(); GSMCallHistoryTest secondTest = new GSMCallHistoryTest(); secondTest.CallHistoryTest(); }
public string PrintMobileInfo(Battery battery, Display display) { string manufacturer = this.Manufacturer; string model = this.Model; string price = this.Price.ToString(); string owner = this.Owner; this.CallHistory = new List<Call>(); string mobileInfo = string.Format("Mobile Info:\nManufacturer:{0}\nModel: {1}\nPrice: {2}\nOwner: {3}", manufacturer, model, price, owner); string result = string.Format("{0} \nBattery info: {1}\nDisplay info: {2}", mobileInfo, battery.PrintInfoForBattery(), display.PrintInfoForDisplay()); return result; }
public GSM(string model, string manufacturer, double?price, string owner, Display display, Battery battery) : this(model, manufacturer, price, owner) { this.display = display; this.battery = battery; this.CallHistory = new List <Call>(); }
public GSM(string modelGSM, string manifactGSM, decimal priceGSM, string ownerGSM, Battery batt, Display displ) : this(modelGSM, manifactGSM) { this.Price = priceGSM; this.Owner = ownerGSM; this.batteryCharacteristics = batt; this.displayCharacteristics = displ; this.callHistory = new List <Call>(); }
public GSM(string model, string manifacturer, string owner, double price, Battery battery, Display display) : this(model, manifacturer, owner, price) { this.Battery = battery; this.Display = display; }
public GSM(string model, string manifacturer, Battery battery, Display display) : this(model, manifacturer, battery) { this.Display = display; }
public GSM(string model, string manifacturer, Battery battery) : this(model, manifacturer) { this.Battery = battery; }
static void Main(string[] args) { Battery battery1 = new Battery("asdasasd", "asdasdasd", "asdasdas", BatteryType.LIon); Display display1 = new Display("10x10", "Niggerian"); GSM number1 = new GSM("samsung", "galaxy", 300, "Shefa", battery1, display1); }
public GSM(string model = null, string manufacturer = null, decimal price = 0, string owner = null, Battery battery = null, Display display = null) { this.Model = model; this.Manufacturer = manufacturer; this.Price = price; this.Owner = owner; this.Battery = battery; this.Display = display; }