public void AddRange(ListBase <T> list) { if (list != null) { foreach (T local in list) { base.Add(local); } } }
public virtual TList <T> Copy() { TList <T> list = new TList <T>(); foreach (T local in Items) { T item = (T)ListBase <T> .MakeCopyOf(local); list.Add(item); } return(list); }
public virtual void CopyTo(TList <T> copyTo) { ArrayList list = new ArrayList(); foreach (T local in copyTo) { list.Add(local.ToString()); } foreach (T local in Items) { T item = (T)ListBase <T> .MakeCopyOf(local); if (list.IndexOf(item.ToString()) < 0) { copyTo.Add(item); } } }
public ListBase <T> FindAll(Predicate <T> match) { if (match == null) { throw new ArgumentNullException("match"); } ListBase <T> base2 = this.Clone() as ListBase <T>; base2.ClearItems(); foreach (T local in base.Items) { if (match(local)) { base2.Add(local); } } return(base2); }
public static bool IsNullOrEmpty(ListBase <T> list) { return((list == null) || (list.Count == 0)); }