public virtual PortItem Add(Type type, string name) { PortItem item = new PortItem { Type = type, Name = name }; Add(item); return(item); }
public PortItem Insert(int index, PortItem item) { if (index > -1 || index <= Count) { InnerList.Insert(index, item); } throw new ArgumentOutOfRangeException("index"); }
public void AddRange(PortItemCollection items) { if (items == null) { throw new ArgumentNullException("items"); } PortItem[] itemArray = new PortItem[items.Count]; items.CopyTo(itemArray, 0); InnerList.AddRange(itemArray); }
public int IndexOf(PortItem item) { for (int index = 0; index < Count; ++index) { if (this[index] == item) { return(index); } } return(-1); }
public virtual PortItem Add(PortItem value) { InnerList.Add(value); return(value); }
public virtual void Remove(PortItem item) => InnerList.Remove(item);
public virtual bool Contains(PortItem item) => InnerList.Contains(item);