Package aQute.bnd.stream
Class EntryPipeline<K,V>
- java.lang.Object
-
- aQute.bnd.stream.EntryPipeline<K,V>
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static class
EntryPipeline.While<T>
-
Constructor Summary
Constructors Constructor Description EntryPipeline(java.util.stream.Stream<? extends java.util.Map.Entry<? extends K,? extends V>> stream)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
allMatch(java.util.function.BiPredicate<? super K,? super V> predicate)
boolean
anyMatch(java.util.function.BiPredicate<? super K,? super V> predicate)
void
close()
<R> R
collect(java.util.function.Supplier<R> supplier, java.util.function.BiConsumer<R,? super java.util.Map.Entry<? extends K,? extends V>> accumulator, java.util.function.BiConsumer<R,R> combiner)
<R,A>
Rcollect(java.util.stream.Collector<? super java.util.Map.Entry<? extends K,? extends V>,A,R> collector)
private static <K,V>
java.util.Comparator<java.util.Map.Entry<K,V>>comparing()
private static <K,V>
java.util.Comparator<java.util.Map.Entry<K,V>>comparingByKey()
private static <K,V>
java.util.Comparator<java.util.Map.Entry<K,V>>comparingByValue()
long
count()
MapStream<K,V>
distinct()
MapStream<K,V>
dropWhile(java.util.function.BiPredicate<? super K,? super V> predicate)
private java.util.stream.Stream<java.util.Map.Entry<K,V>>
dropWhile(java.util.function.Predicate<? super java.util.Map.Entry<K,V>> predicate)
MapStream<K,V>
dropWhileKey(java.util.function.Predicate<? super K> predicate)
MapStream<K,V>
dropWhileValue(java.util.function.Predicate<? super V> predicate)
java.util.stream.Stream<java.util.Map.Entry<K,V>>
entries()
MapStream<K,V>
filter(java.util.function.BiPredicate<? super K,? super V> filter)
MapStream<K,V>
filterKey(java.util.function.Predicate<? super K> filter)
MapStream<K,V>
filterValue(java.util.function.Predicate<? super V> filter)
java.util.Optional<java.util.Map.Entry<K,V>>
findAny()
java.util.Optional<java.util.Map.Entry<K,V>>
findFirst()
<R,S>
MapStream<R,S>flatMap(java.util.function.BiFunction<? super K,? super V,? extends MapStream<? extends R,? extends S>> mapper)
java.util.stream.DoubleStream
flatMapToDouble(java.util.function.BiFunction<? super K,? super V,? extends java.util.stream.DoubleStream> mapper)
java.util.stream.IntStream
flatMapToInt(java.util.function.BiFunction<? super K,? super V,? extends java.util.stream.IntStream> mapper)
java.util.stream.LongStream
flatMapToLong(java.util.function.BiFunction<? super K,? super V,? extends java.util.stream.LongStream> mapper)
<R> java.util.stream.Stream<R>
flatMapToObj(java.util.function.BiFunction<? super K,? super V,? extends java.util.stream.Stream<? extends R>> mapper)
void
forEach(java.util.function.BiConsumer<? super K,? super V> consumer)
void
forEachOrdered(java.util.function.BiConsumer<? super K,? super V> consumer)
boolean
isParallel()
java.util.Iterator<java.util.Map.Entry<K,V>>
iterator()
java.util.stream.Stream<K>
keys()
MapStream<K,V>
limit(long maxSize)
<R,S>
MapStream<R,S>map(java.util.function.BiFunction<? super K,? super V,? extends java.util.Map.Entry<? extends R,? extends S>> mapper)
<R> MapStream<R,V>
mapKey(java.util.function.Function<? super K,? extends R> mapper)
java.util.stream.DoubleStream
mapToDouble(java.util.function.ToDoubleBiFunction<? super K,? super V> mapper)
java.util.stream.IntStream
mapToInt(java.util.function.ToIntBiFunction<? super K,? super V> mapper)
java.util.stream.LongStream
mapToLong(java.util.function.ToLongBiFunction<? super K,? super V> mapper)
<R> java.util.stream.Stream<R>
mapToObj(java.util.function.BiFunction<? super K,? super V,? extends R> mapper)
<S> MapStream<K,S>
mapValue(java.util.function.Function<? super V,? extends S> mapper)
java.util.Optional<java.util.Map.Entry<K,V>>
max(java.util.Comparator<? super java.util.Map.Entry<K,V>> comparator)
java.util.Optional<java.util.Map.Entry<K,V>>
maxByKey(java.util.Comparator<? super K> comparator)
java.util.Optional<java.util.Map.Entry<K,V>>
maxByValue(java.util.Comparator<? super V> comparator)
java.util.Optional<java.util.Map.Entry<K,V>>
min(java.util.Comparator<? super java.util.Map.Entry<K,V>> comparator)
java.util.Optional<java.util.Map.Entry<K,V>>
minByKey(java.util.Comparator<? super K> comparator)
java.util.Optional<java.util.Map.Entry<K,V>>
minByValue(java.util.Comparator<? super V> comparator)
boolean
noneMatch(java.util.function.BiPredicate<? super K,? super V> predicate)
MapStream<K,V>
onClose(java.lang.Runnable closeHandler)
MapStream<K,V>
parallel()
MapStream<K,V>
peek(java.util.function.BiConsumer<? super K,? super V> peek)
MapStream<K,V>
peekKey(java.util.function.Consumer<? super K> peek)
MapStream<K,V>
peekValue(java.util.function.Consumer<? super V> peek)
MapStream<K,V>
sequential()
MapStream<K,V>
skip(long n)
MapStream<K,V>
sorted()
MapStream<K,V>
sorted(java.util.Comparator<? super java.util.Map.Entry<K,V>> comparator)
MapStream<K,V>
sortedByKey()
MapStream<K,V>
sortedByKey(java.util.Comparator<? super K> comparator)
MapStream<K,V>
sortedByValue()
MapStream<K,V>
sortedByValue(java.util.Comparator<? super V> comparator)
java.util.Spliterator<java.util.Map.Entry<K,V>>
spliterator()
MapStream<K,V>
takeWhile(java.util.function.BiPredicate<? super K,? super V> predicate)
private java.util.stream.Stream<java.util.Map.Entry<K,V>>
takeWhile(java.util.function.Predicate<? super java.util.Map.Entry<K,V>> predicate)
MapStream<K,V>
takeWhileKey(java.util.function.Predicate<? super K> predicate)
MapStream<K,V>
takeWhileValue(java.util.function.Predicate<? super V> predicate)
java.util.Map.Entry<K,V>[]
toArray()
MapStream<K,V>
unordered()
java.util.stream.Stream<V>
values()
-
-
-
Method Detail
-
isParallel
public boolean isParallel()
-
close
public void close()
-
filterValue
public MapStream<K,V> filterValue(java.util.function.Predicate<? super V> filter)
- Specified by:
filterValue
in interfaceMapStream<K,V>
-
map
public <R,S> MapStream<R,S> map(java.util.function.BiFunction<? super K,? super V,? extends java.util.Map.Entry<? extends R,? extends S>> mapper)
-
mapKey
public <R> MapStream<R,V> mapKey(java.util.function.Function<? super K,? extends R> mapper)
-
mapValue
public <S> MapStream<K,S> mapValue(java.util.function.Function<? super V,? extends S> mapper)
-
mapToObj
public <R> java.util.stream.Stream<R> mapToObj(java.util.function.BiFunction<? super K,? super V,? extends R> mapper)
-
mapToInt
public java.util.stream.IntStream mapToInt(java.util.function.ToIntBiFunction<? super K,? super V> mapper)
-
mapToLong
public java.util.stream.LongStream mapToLong(java.util.function.ToLongBiFunction<? super K,? super V> mapper)
-
mapToDouble
public java.util.stream.DoubleStream mapToDouble(java.util.function.ToDoubleBiFunction<? super K,? super V> mapper)
- Specified by:
mapToDouble
in interfaceMapStream<K,V>
-
flatMap
public <R,S> MapStream<R,S> flatMap(java.util.function.BiFunction<? super K,? super V,? extends MapStream<? extends R,? extends S>> mapper)
-
flatMapToObj
public <R> java.util.stream.Stream<R> flatMapToObj(java.util.function.BiFunction<? super K,? super V,? extends java.util.stream.Stream<? extends R>> mapper)
- Specified by:
flatMapToObj
in interfaceMapStream<K,V>
-
flatMapToInt
public java.util.stream.IntStream flatMapToInt(java.util.function.BiFunction<? super K,? super V,? extends java.util.stream.IntStream> mapper)
- Specified by:
flatMapToInt
in interfaceMapStream<K,V>
-
flatMapToLong
public java.util.stream.LongStream flatMapToLong(java.util.function.BiFunction<? super K,? super V,? extends java.util.stream.LongStream> mapper)
- Specified by:
flatMapToLong
in interfaceMapStream<K,V>
-
flatMapToDouble
public java.util.stream.DoubleStream flatMapToDouble(java.util.function.BiFunction<? super K,? super V,? extends java.util.stream.DoubleStream> mapper)
- Specified by:
flatMapToDouble
in interfaceMapStream<K,V>
-
comparingByKey
private static <K,V> java.util.Comparator<java.util.Map.Entry<K,V>> comparingByKey()
-
comparingByValue
private static <K,V> java.util.Comparator<java.util.Map.Entry<K,V>> comparingByValue()
-
comparing
private static <K,V> java.util.Comparator<java.util.Map.Entry<K,V>> comparing()
-
sorted
public MapStream<K,V> sorted(java.util.Comparator<? super java.util.Map.Entry<K,V>> comparator)
-
sortedByKey
public MapStream<K,V> sortedByKey()
- Specified by:
sortedByKey
in interfaceMapStream<K,V>
-
sortedByKey
public MapStream<K,V> sortedByKey(java.util.Comparator<? super K> comparator)
- Specified by:
sortedByKey
in interfaceMapStream<K,V>
-
sortedByValue
public MapStream<K,V> sortedByValue()
- Specified by:
sortedByValue
in interfaceMapStream<K,V>
-
sortedByValue
public MapStream<K,V> sortedByValue(java.util.Comparator<? super V> comparator)
- Specified by:
sortedByValue
in interfaceMapStream<K,V>
-
forEachOrdered
public void forEachOrdered(java.util.function.BiConsumer<? super K,? super V> consumer)
- Specified by:
forEachOrdered
in interfaceMapStream<K,V>
-
collect
public <R,A> R collect(java.util.stream.Collector<? super java.util.Map.Entry<? extends K,? extends V>,A,R> collector)
-
collect
public <R> R collect(java.util.function.Supplier<R> supplier, java.util.function.BiConsumer<R,? super java.util.Map.Entry<? extends K,? extends V>> accumulator, java.util.function.BiConsumer<R,R> combiner)
-
max
public java.util.Optional<java.util.Map.Entry<K,V>> max(java.util.Comparator<? super java.util.Map.Entry<K,V>> comparator)
-
maxByKey
public java.util.Optional<java.util.Map.Entry<K,V>> maxByKey(java.util.Comparator<? super K> comparator)
-
maxByValue
public java.util.Optional<java.util.Map.Entry<K,V>> maxByValue(java.util.Comparator<? super V> comparator)
- Specified by:
maxByValue
in interfaceMapStream<K,V>
-
min
public java.util.Optional<java.util.Map.Entry<K,V>> min(java.util.Comparator<? super java.util.Map.Entry<K,V>> comparator)
-
minByKey
public java.util.Optional<java.util.Map.Entry<K,V>> minByKey(java.util.Comparator<? super K> comparator)
-
minByValue
public java.util.Optional<java.util.Map.Entry<K,V>> minByValue(java.util.Comparator<? super V> comparator)
- Specified by:
minByValue
in interfaceMapStream<K,V>
-
takeWhile
public MapStream<K,V> takeWhile(java.util.function.BiPredicate<? super K,? super V> predicate)
-
takeWhileKey
public MapStream<K,V> takeWhileKey(java.util.function.Predicate<? super K> predicate)
- Specified by:
takeWhileKey
in interfaceMapStream<K,V>
-
takeWhileValue
public MapStream<K,V> takeWhileValue(java.util.function.Predicate<? super V> predicate)
- Specified by:
takeWhileValue
in interfaceMapStream<K,V>
-
dropWhile
public MapStream<K,V> dropWhile(java.util.function.BiPredicate<? super K,? super V> predicate)
-
dropWhileKey
public MapStream<K,V> dropWhileKey(java.util.function.Predicate<? super K> predicate)
- Specified by:
dropWhileKey
in interfaceMapStream<K,V>
-
dropWhileValue
public MapStream<K,V> dropWhileValue(java.util.function.Predicate<? super V> predicate)
- Specified by:
dropWhileValue
in interfaceMapStream<K,V>
-
takeWhile
private java.util.stream.Stream<java.util.Map.Entry<K,V>> takeWhile(java.util.function.Predicate<? super java.util.Map.Entry<K,V>> predicate)
-
-