public IEnumerable <DataPage <TPrimaryKey, TRow> > GetAllPages() => _map.GetItems(false).Select(s => s.Value);
Пример #2
0
 public IEnumerable <TRow> Scan(Func <TIndexKey, bool> predicate, Retrieval retrieval)
 => _map.GetItems(retrieval.Reverse)
 .Where(d => predicate(d.Key))
 .Skip(retrieval.Skip ?? 0)
 .Take(retrieval.Take ?? Int32.MaxValue)
 .Select(s => s.Value.Row);
 public IEnumerable <IGrouping <TIndexKey, TRow> > GroupScan(Func <TIndexKey, bool> predicate, Retrieval retrieval)
 => _map.GetItems(retrieval.Reverse)
 .Where(d => predicate(d.Key))
 .Skip(retrieval.Skip ?? 0)
 .Take(retrieval.Take ?? Int32.MaxValue)
 .Select(r => new RedBlackNonUniqueNonClusteredGrouping <TPrimaryKey, TIndexKey, TRow>(r.Key, r.Value));