Interface SplitableIterable<T>

All Superinterfaces:
Iterable<T>
All Known Subinterfaces:
GenericIterator.Iterable<T>, IArray<T>, ICollection<T>, IDeque<T>, IList<T>, IListMap<K,V>, IMap<K,V>, IMultiset<T>, ISet<T>, ISetMap<K,V>, IStreamable<T>
All Known Implementing Classes:
AbstractMap, AbstractMultiset, AbstractSet, AbstractSetUsingMap, ArrayDeque, EmptyHashMap, EmptyHashSet, EntryStreamable, HashListMap, HashMap, HashMultiset, HashSet, HashSetMap, LeafNode, Maybe, NotNull, OrderedListMap, OrderedMap, OrderedMultiset, OrderedSet, OrderedSetMap, TemplateSetMap, TransformStreamable, TreeList, TreeListMap, TreeMap, TreeMultiset, TreeSet, TreeSetMap, TrieArray

public interface SplitableIterable<T> extends Iterable<T>
Extension of Iterable for objects whose iterator method returns a SplitableIterator.
  • Method Details

    • iterator

      Specified by:
      iterator in interface Iterable<T>
    • forEachThrows

      default <E extends Exception> void forEachThrows(@Nonnull Proc1Throws<T,E> proc) throws E
      Processes every value using the provided function.
      Throws:
      E
    • reduce

      default <V> V reduce(V initialValue, Func2<V,T,V> accumulator)
      Apply the specified accumulator to all elements in iterator order calling the accumulator function for each element. The first call to accumulator is passed initialValue and first element in the sequence. All remaining calls to accumulator are passed the result from the previous call and next element in the sequence.
      Parameters:
      initialValue - value passed to accumulator on first call
      accumulator - method called to compute result
      Returns:
      result from last call to accumulator
    • reduceThrows

      default <V, E extends Exception> V reduceThrows(V initialValue, Sum1Throws<T,V,E> accumulator) throws E
      Throws:
      E
    • indexedForEach

      default void indexedForEach(@Nonnull IndexedProc1<T> proc)
      Version of forEach that includes an integer index along with each value. Note the index is based solely on the sequence of calls to the lambda. It is not based on any key value associated with the collection (i.e. Integer key in a map or index of an array). First value is always 0, second is always 1, etc.
    • indexedForEachThrows

      default <E extends Exception> void indexedForEachThrows(@Nonnull IndexedProc1Throws<T,E> proc) throws E
      Version of forEachThrows that includes an integer index along with each value. Note the index is based solely on the sequence of calls to the lambda. It is not based on any key value associated with the collection (i.e. Integer key in a map or index of an array). First value is always 0, second is always 1, etc.
      Throws:
      E