List of usage examples for java.util.stream StreamSupport doubleStream
public static DoubleStream doubleStream(Spliterator.OfDouble spliterator, boolean parallel)
From source file:org.briljantframework.array.AbstractDoubleArray.java
@Override public DoubleStream stream() { PrimitiveIterator.OfDouble ofDouble = new PrimitiveIterator.OfDouble() { public int current = 0; @Override/* w w w . j av a 2 s .c o m*/ public double nextDouble() { return get(current++); } @Override public boolean hasNext() { return current < size(); } }; Spliterator.OfDouble spliterator = Spliterators.spliterator(ofDouble, size(), Spliterator.SIZED); return StreamSupport.doubleStream(spliterator, false); }