Class Iterables


  • public class Iterables
    extends java.lang.Object
    Created by luc on 25/11/15.
    • Constructor Summary

      Constructors 
      Constructor Description
      Iterables()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static <E> java.lang.Iterable<E> concatenate​(java.lang.Iterable<? extends E>... iterables)  
      static <E> java.lang.Iterable<E> concatenate​(java.lang.Iterable<java.lang.Iterable<? extends E>> iterables)  
      static <T> java.lang.Iterable<T> conditional​(java.lang.Iterable<T> original, Iterables.Condition<? super T> condition)  
      static <T,​C>
      java.lang.Iterable<C>
      convert​(java.lang.Iterable<T> original, Iterables.Converter<? super T,​C> converter)  
      static <T> java.lang.Iterable<T> exclude​(java.lang.Iterable<T> original, T value)  
      static <T> java.lang.Iterable<T> forArray​(T... array)  
      static java.lang.Iterable<java.lang.Integer> forIntArray​(int... array)  
      static <E> E[] makeArray​(java.lang.Iterable<E> iter)  
      static <E> java.util.Collection<E> makeCollection​(java.lang.Iterable<E> iter)  
      static <E> java.util.List<E> makeList​(java.lang.Iterable<E> iter)  
      static <T> java.lang.Iterable<T> nonNull​(java.lang.Iterable<T> original)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • Iterables

        public Iterables()
    • Method Detail

      • forIntArray

        public static java.lang.Iterable<java.lang.Integer> forIntArray​(int... array)
      • forArray

        public static <T> java.lang.Iterable<T> forArray​(T... array)
      • exclude

        public static <T> java.lang.Iterable<T> exclude​(java.lang.Iterable<T> original,
                                                        T value)
      • nonNull

        public static <T> java.lang.Iterable<T> nonNull​(java.lang.Iterable<T> original)
      • conditional

        public static <T> java.lang.Iterable<T> conditional​(java.lang.Iterable<T> original,
                                                            Iterables.Condition<? super T> condition)
      • convert

        public static <T,​C> java.lang.Iterable<C> convert​(java.lang.Iterable<T> original,
                                                                Iterables.Converter<? super T,​C> converter)
      • concatenate

        @SafeVarargs
        public static <E> java.lang.Iterable<E> concatenate​(java.lang.Iterable<? extends E>... iterables)
      • concatenate

        public static <E> java.lang.Iterable<E> concatenate​(java.lang.Iterable<java.lang.Iterable<? extends E>> iterables)
      • makeList

        public static <E> java.util.List<E> makeList​(java.lang.Iterable<E> iter)
      • makeCollection

        public static <E> java.util.Collection<E> makeCollection​(java.lang.Iterable<E> iter)
      • makeArray

        public static <E> E[] makeArray​(java.lang.Iterable<E> iter)