private void RemoveFloorsConnection() { foreach (var connection in OutgoingSections.Where(x => x is FloorsConnectionSection).ToArray()) { (connection.Parent as Floor).RemoveObject(connection); } }
public virtual void RemoveSection(Section section) { if (section.First == this) { OutgoingSections.Remove(section); } if (section.Last == this) { IncomingSections.Remove(section); } }
public virtual void AddSection(Section section) { if (section.First == this) { if (!OutgoingSections.Contains(section)) { OutgoingSections.Add(section); } } if (section.Last == this) { if (!IncomingSections.Contains(section)) { IncomingSections.Add(section); } } }