Class Iterables

java.lang.Object
org.elasticsearch.common.util.iterable.Iterables

public class Iterables extends Object
  • Constructor Details

    • Iterables

      public Iterables()
  • Method Details

    • concat

      @SafeVarargs public static <T> Iterable<T> concat(Iterable<T>... inputs)
    • flatten

      public static <T> Iterable<T> flatten(Iterable<? extends Iterable<T>> inputs)
      Flattens the two level Iterable into a single Iterable. Note that this pre-caches the values from the outer Iterable, but not the values from the inner one.
    • get

      public static <T> T get(Iterable<T> iterable, int position)
    • indexOf

      public static <T> int indexOf(Iterable<T> iterable, Predicate<T> predicate)
    • size

      public static long size(Iterable<?> iterable)