Interface IDirectedCollectionValue<T>

A sized generic collection, that can be enumerated backwards.


IEnumerable<T>, System.Collections.IEnumerable, System.IFormattable, ICollectionValue<T>, IDirectedEnumerable<T>, IShowable

Implemented by

ArrayBase<T>, ArrayBase<T>.Range, ArrayList<T>, CircularQueue<T>, DirectedCollectionBase<T>, DirectedCollectionValueBase<T>, GuardedDirectedCollectionValue<T>, GuardedIndexedSorted<T>, GuardedList<T>, GuardedQueue<T>, GuardedSequenced<T>, GuardedSorted<T>, HashedArrayList<T>, HashedLinkedList<T>, LinkedList<T>, SequencedBase<T>, SortedArray<T>, TreeBag<T>, TreeSet<T>, WrappedArray<T>


IIndexed<T>, IIndexedSorted<T>, IList<T>, IPersistentSorted<T>, IQueue<T>, ISequenced<T>, ISorted<T>, IStack<T>

Method overview

Backwards() ,
FindLast(Fun<T,bool> predicate, out T item)

Method details

A IDirectedCollectionValue<T> Backwards() Create a collection containing the same items as this collection, but whose enumerator will enumerate the items backwards. The new collection will become invalid if the original is modified. Method typically used as in foreach (T x in coll.Backwards()) {...}
Returns:The backwards collection.
A bool FindLast(Fun<T,bool> predicate, out T item) Check if there exists an item that satisfies a specific predicate in this collection and return the first one in enumeration order.
Returns:True is such an item exists
predicate:A delegate (Fun<A1,R> with R == bool) defining the predicate