Skip to content

reverse

Mahmoud Ben Hassine edited this page Oct 13, 2015 · 3 revisions

reverse

Synopsis

Reverse elements in a stream.

Parameters

N/A

Example

Stream<String> stream = Stream.of("a", "b");

UStream.unixify(stream)
   .reverse()
   .to(stdOut()); // prints "b", "a"

// Or

UStream.from(stream)
   .pipe(reverse())
   .to(stdOut()); // prints "b", "a"
Clone this wiki locally