Class Streams

java.lang.Object
org.assertj.core.util.Streams

public class Streams extends Object
  • Constructor Details

    • Streams

      public Streams()
  • Method Details

    • stream

      public static <T> Stream<T> stream(Iterable<T> iterable)
      Returns a sequential Stream of the contents of iterable, delegating to Collection.stream() if possible.
      Type Parameters:
      T - the stream type
      Parameters:
      iterable - the iterable to built the stream from
      Returns:
      the stream built from the given Iterable
    • stream

      public static <T> Stream<T> stream(Iterator<T> iterator)