public ILaptop CreateLaptop(string model) { var laptop = new SamsungLaptop { Model = model }; laptop.Create(); return(laptop); }
public DecoratorViewModel() { Widget widget = new ConcreteSamsung(); widget = new SamsungLaptop(widget); widget = new SamsungTab2(widget); this.WidgetDescription = widget.GetDescription(); this.WidgetCost = string.Format("{0:C}", widget.GetCost()); }