public static interface Linkable.Int
An int primitive specialisation of Linkable.
-
Method Summary
Modifier and TypeMethodDescriptiondefault Linkable.Intfilter(IntPredicate predicate) Returns a Linkable.Int that wraps this Linkable.Int and filters values using the provided predicate function.voidlink(IntConsumer consumer) Link to a Consumer to process values.default Linkable.Intmap(IntUnaryOperator function) Returns a Linkable.Int that wraps this Linkable.Int and transforms values using the provided mapping function.default <R> Linkable<R> mapTo(IntFunction<? extends R> function) Returns a Linkable that wraps this Linkable.Int and transforms values using the provided mapping function.
-
Method Details
-
link
Link to a Consumer to process values. Setting a Consumer completes the pipeline. Only one Consumer may be set on a Linkable pipeline - to use multiple consumers, acquire a new Linkable from the original source.- Parameters:
consumer- function to process received values.
-
map
Returns a Linkable.Int that wraps this Linkable.Int and transforms values using the provided mapping function.- Parameters:
function- transform values- Returns:
-
mapTo
Returns a Linkable that wraps this Linkable.Int and transforms values using the provided mapping function.- Type Parameters:
R- generic type of returned Linkable- Parameters:
function- transform values- Returns:
- Linkable
-
filter
Returns a Linkable.Int that wraps this Linkable.Int and filters values using the provided predicate function.- Parameters:
predicate-- Returns:
-