Java Utililty Methods Stream Create

List of utility methods to do Stream Create

Description

The list of methods to do Stream Create are organized into topic(s).

Method

StreamasStream(Collection source, boolean parallel)
Returns the given collection as stream.
return parallel ? source.parallelStream() : source.stream();
StreamasStream(Iterable sourceIterable)
as Stream
return asStream(sourceIterable.iterator());
StreamasStream(Iterator iter)
as Stream
return asStream(iter, false);
StreamasStream(Iterator sourceIterator)
Converts an Iterator to a java Stream
return asStream(sourceIterator, false);
StreamasStream(T... objs)
as Stream
return asList(objs).stream();
StreamasStream(T[] items)
as Stream
return nullGuard(items).stream();