MCPcopy
hub / github.com/google/guava / stream

Method stream

guava/src/com/google/common/collect/Streams.java:66–70  ·  view source on GitHub ↗

Returns a sequential {@link Stream} of the contents of {@code iterable}, delegating to {@link Collection#stream} if possible.

(Iterable<T> iterable)

Source from the content-addressed store, hash-verified

64 * Collection#stream} if possible.
65 */
66 public static <T extends @Nullable Object> Stream<T> stream(Iterable<T> iterable) {
67 return (iterable instanceof Collection)
68 ? ((Collection<T>) iterable).stream()
69 : StreamSupport.stream(iterable.spliterator(), false);
70 }
71
72 /**
73 * Returns {@link Collection#stream}.

Callers 5

spliteratorMethod · 0.95
streamMethod · 0.95
concatMethod · 0.45
zipMethod · 0.45
mapWithIndexMethod · 0.45

Calls 5

spliteratorMethod · 0.65
getMethod · 0.65
isPresentMethod · 0.45
ofMethod · 0.45
emptyMethod · 0.45

Tested by

no test coverage detected