public void Add(IFurniture furniture) { if (furniture != null) { this.furnitures.Add(furniture); } }
public void Remove(IFurniture furniture) { var foundFurniture = this.Find(furniture.Model); if (foundFurniture != null) { this.furnitures.Remove(foundFurniture as Furniture); } }
public void Remove(IFurniture furniture) { if (this.Furnitures.Count > 0) { IFurniture firstFurniture = this.Furnitures.FirstOrDefault(f => f.Model == furniture.Model); this.Furnitures.Remove(firstFurniture); } }
public void Remove(IFurniture furniture) { if (furniture == null) { throw new ArgumentNullException("Cannot remove null from furnitures."); } this.furnitures.Remove(furniture); }
public void Add(IFurniture furniture) { if (furniture == null) { throw new ArgumentNullException("Cannot add null to furnitures."); } this.furnitures.Add(furniture); }
public void Add(IFurniture furniture) { if (furniture == null) { throw new ArgumentNullException("Furniture cannot be null"); } this.Furnitures.Add(furniture); }
public void Add(IFurniture furniture) { if (furniture == null) { throw new ArgumentNullException("Threre is no furniture"); } this.catalogList.Add(furniture); }
public void Remove(IFurniture furniture) { if (furniture == null) { throw new ArgumentNullException("Furniture cannot be null"); } this.furnitures.Remove(furniture); }
public void Remove(IFurniture furniture) => this.Furnitures.Remove(furniture);
public void UpdateUI(IFurniture furniture, FurnitureTypes furnitureType) { Image img = new Image(); img.Width = furniture.Width; img.Height = furniture.Height; img.Visibility = Visibility.Visible; img.Margin = new Thickness(furniture.X, furniture.Y, 0, 0); //img.Stretch = Stretch.Fill; img.Stretch = Stretch.Fill; furniture.Img = img; objects = room.GetFurniture(); switch (furnitureType) { case FurnitureTypes.Bed: img.Source = new BitmapImage(new Uri(System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location) + @"\Images\Bed2.png")); break; case FurnitureTypes.Bed2: img.Source = new BitmapImage(new Uri(System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location) + @"\Images\Bed2.png")); break; case FurnitureTypes.BookShelf: img.Source = new BitmapImage(new Uri(System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location) + @"\Images\BookShelf.png")); break; case FurnitureTypes.Couch: img.Source = new BitmapImage(new Uri(System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location) + @"\Images\Couch.png")); break; case FurnitureTypes.DeskChair: img.Source = new BitmapImage(new Uri(System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location) + @"\Images\DeskChair.png")); break; case FurnitureTypes.Dresser: img.Source = new BitmapImage(new Uri(System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location) + @"\Images\Dresser.png")); break; case FurnitureTypes.Recliner: img.Source = new BitmapImage(new Uri(System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location) + @"\Images\Recliner.png")); break; case FurnitureTypes.Rug: img.Source = new BitmapImage(new Uri(System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location) + @"\Images\Rug.png")); break; case FurnitureTypes.Sofa: img.Source = new BitmapImage(new Uri(System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location) + @"\Images\Sofa.png")); break; case FurnitureTypes.Stove: img.Source = new BitmapImage(new Uri(System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location) + @"\Images\Stove.png")); break; case FurnitureTypes.Table: img.Source = new BitmapImage(new Uri(System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location) + @"\Images\Table.png")); break; case FurnitureTypes.TVStand: img.Source = new BitmapImage(new Uri(System.IO.Path.GetDirectoryName(System.Reflection.Assembly.GetExecutingAssembly().Location) + @"\Images\TVStand.png")); break; } this.Grid.Children.Add(furniture.Img); }
public void Add(IFurniture furniture) { this.Furnitures.Add(furniture); }
public void Add(IFurniture furniture) { this.furnitures.Add(furniture); //this.furnitures.OrderBy(); }
public void Remove(IFurniture furniture) { Validator.ValidateNullObject(furniture, "Furniture to remove cannot be null!"); this.furnitures.Remove(furniture); }
public void Add(IFurniture furniture) { }
public void Remove(IFurniture furniture) { this.catalog.Remove(furniture); }
public void Add(IFurniture furniture) { this.catalog.Add(furniture); }
public void Remove(IFurniture furniture) { // Removing furniture removes the first occurance. If such is not found, nothing happens. this.furnitures.Remove(furniture); }
public void Add(IFurniture furniture) { // Adding duplicate furniture is allowed. this.furnitures.Add(furniture); }
public void Remove(IFurniture furniture) { }
public void Remove(IFurniture furniture) { if (_furnitures.Any( x => x.Model == furniture.Model && x.Price == furniture.Price && x.Material == furniture.Material && x.Height == furniture.Height )) { _furnitures.Remove(furniture); } }
public void Add(IFurniture furniture) { //TODO: check for null this.Furnitures.Add(furniture); }
public void Add(IFurniture furniture) { if (furniture == null) { throw new ArgumentOutOfRangeException("Furnite value cannot be null! Cannot add furniture with null value!"); } this.furnitures.Add(furniture); }
public void Add(IFurniture furniture) { models.Add(furniture); }
public void Remove(IFurniture furniture) { furnitureList.Remove(furniture); }
public void Add(IFurniture furniture) { this.furnitures.Add(furniture); //this.Furnitures = this.Furnitures.OrderBy(x => x.Price).ThenBy(x => x.Model).ToList(); }
public void PlaceFurniture(IFurniture furniture) { return; }
public void AddFurniture(IFurniture furniture) { Guard.WhenArgument(furniture, furniture.GetType().Name).IsNull().Throw(); this.furniture.Add(furniture.Model, furniture); }
public void Remove(IFurniture furniture) { this.Furnitures.Remove(furniture); }
public void Add(IFurniture furniture) { this.Furnitures.Add((furniture)); }
public void Add(IFurniture furniture) => this.Furnitures.Add(furniture);
public void Add(IFurniture furniture) { furnitures.Add(furniture); }
public void Remove(IFurniture furniture) { this.collectionOfFurnitures.Remove(furniture); }
public void Add(IFurniture furniture) { this.furnitures.Add(furniture); var sortedFurnitures = this.Furnitures .OrderBy(x => x.Price) .ThenBy(x => x.Model) .ToList(); this.furnitures = sortedFurnitures; }
public Clients(IFurniture furniture, string segment) { chair = furniture.CreateChair(segment); table = furniture.CreateTable(segment); sofa = furniture.CreateSofa(segment); }
public void Add(IFurniture furniture) { this.Furnitures.Add(furniture); this.Furnitures = this.Furnitures.OrderBy(f => f.Price).ThenBy(f => f.Model).ToList(); }
public void Remove(IFurniture furniture) { if (furniture == null) { throw new ArgumentOutOfRangeException("Furnite value cannot be null! Cannot remove furniture with null value!"); } foreach (var furn in this.Furnitures) { if (ReferenceEquals(furn, furniture)) { this.furnitures.Remove(furn); break; } } }
public void Remove(IFurniture furniture) { if (this.furnitures.Contains(furniture)) { this.furnitures.Remove(furniture); } // var item = this.furnitures.FirstOrDefault(x => x.Material == furniture.Material && x.Model == furniture.Model && x.Price == furniture.Price); }
public void Remove(IFurniture furniture) { this.furnitures.Remove(furniture); }
protected override string Execute(ICompany company, IFurniture furniture) { company.Add(furniture); return(string.Format(Messages.FurnitureAddedSuccessMessage, furniture.Model, company.Name)); }
public Sprite GetSprite(IFurniture furniture) { return(GetSprite(furniture.GetOrientation())); }
public void Remove(IFurniture furniture) { if (this.initialFurnitures.Contains (furniture)) { this.initialFurnitures.Remove (furniture); } }
public void Remove(IFurniture selected) { throw new NotImplementedException(); }
public FurnitureApp(IFurniture f) { this.f = f; }
public void Add(IFurniture furniture) { Validator.ValidateNullObject(furniture, "Furniture to add cannot be null!"); this.furnitures.Add(furniture); }
public void Add(IFurniture furniture) { this.furnitures.Add(furniture); }
public void Add(IFurniture furniture) { furnitureList.Add(furniture); }