public ReadOnlyApiCollection(Func <int, TValue> GetNewWrapper, Func <int> GetCount) { this.GetNewWrapperFunc = GetNewWrapper; this.GetCountFunc = GetCount; wrapperList = new List <TValue>(); enumerator = new CollectionDataEnumerator <TValue>(x => this[x], GetCount); }
public ReadOnlyCollectionData(Func <int, TValue> Getter, Func <int> GetCount) { this.Getter = Getter; this.GetCountFunc = GetCount; enumerator = new CollectionDataEnumerator <TValue>(x => this[x], GetCount); }