public abstract class Spies extends Object
| Constructor and Description |
|---|
Spies() |
| Modifier and Type | Method and Description |
|---|---|
static <T1,T2> BiConsumer<T1,T2> |
monitor(BiConsumer<T1,T2> consumer,
AtomicLong calls)
Monitors calls to a binary consumer.
|
static <T1,T2,R> BiFunction<T1,T2,R> |
monitor(BiFunction<T1,T2,R> function,
AtomicLong calls)
Monitors calls to a binary function.
|
static <T1,T2> BiPredicate<T1,T2> |
monitor(BiPredicate<T1,T2> predicate,
AtomicLong calls)
Monitors calls to a binary predicate
|
static BooleanSupplier |
monitor(BooleanSupplier proposition,
AtomicLong calls)
Monitors calls to a proposition.
|
static <T> Consumer<T> |
monitor(Consumer<T> consumer,
AtomicLong calls)
Monitors calls to an consumer.
|
static <T,R> Function<T,R> |
monitor(Function<T,R> function,
AtomicLong calls)
Monitors calls to a function.
|
static <T> Predicate<T> |
monitor(Predicate<T> predicate,
AtomicLong calls)
Monitors calls to a predicate.
|
static Runnable |
monitor(Runnable runnable,
AtomicLong calls)
Monitors calls to a runnable.
|
static <R> Supplier<R> |
monitor(Supplier<R> supplier,
AtomicLong calls)
Monitors calls to a supplier.
|
static <T1,T2,T3> TriConsumer<T1,T2,T3> |
monitor(TriConsumer<T1,T2,T3> consumer,
AtomicLong calls)
Monitors calls to a ternary consumer.
|
static <T1,T2,T3,R> |
monitor(TriFunction<T1,T2,T3,R> function,
AtomicLong calls)
Monitors calls to a ternary function.
|
static <T1,T2,T3> TriPredicate<T1,T2,T3> |
monitor(TriPredicate<T1,T2,T3> predicate,
AtomicLong calls)
Monitors calls to a ternary predicate.
|
static <T1,T2> BiConsumer<T1,T2> |
spy(BiConsumer<T1,T2> consumer,
Box<T1> param1,
Box<T2> param2)
Proxies a binary consumer spying for parameters.
|
static <T1,T2,R> BiFunction<T1,T2,R> |
spy(BiFunction<T1,T2,R> function,
Box<R> result,
Box<T1> param1,
Box<T2> param2)
Proxies a binary function spying for result and parameters.
|
static <T1,T2> BiPredicate<T1,T2> |
spy(BiPredicate<T1,T2> predicate,
Box<Boolean> result,
Box<T1> param1,
Box<T2> param2)
Proxies a binary predicate spying for result and parameters.
|
static BooleanSupplier |
spy(BooleanSupplier proposition,
Box<Boolean> result)
Proxies a proposition, spying for result.
|
static <T> Consumer<T> |
spy(Consumer<T> consumer,
Box<T> param)
Proxies an consumer spying for parameter.
|
static <T,R> Function<T,R> |
spy(Function<T,R> function,
Box<R> result,
Box<T> param)
Proxies a function spying for result and parameter.
|
static <T> Predicate<T> |
spy(Predicate<T> predicate,
Box<Boolean> result,
Box<T> param)
Proxies a predicate spying for result and parameter.
|
static <R> Supplier<R> |
spy(Supplier<R> supplier,
Box<R> result)
Proxies a supplier, spying for result.
|
static <T1,T2,T3> TriConsumer<T1,T2,T3> |
spy(TriConsumer<T1,T2,T3> consumer,
Box<T1> param1,
Box<T2> param2,
Box<T3> param3)
Proxies a ternary consumer spying for parameters.
|
static <T1,T2,T3,R> |
spy(TriFunction<T1,T2,T3,R> function,
Box<R> result,
Box<T1> param1,
Box<T2> param2,
Box<T3> param3)
Proxies a ternary function spying for result and parameters.
|
static <T1,T2,T3> TriPredicate<T1,T2,T3> |
spy(TriPredicate<T1,T2,T3> predicate,
Box<Boolean> result,
Box<T1> param1,
Box<T2> param2,
Box<T3> param3)
Proxies a ternary predicate spying for result and parameters.
|
static <T1,T2> BiConsumer<T1,T2> |
spy1st(BiConsumer<T1,T2> consumer,
Box<T1> param1)
Proxies a binary consumer spying for first parameter.
|
static <T1,T2,R> BiFunction<T1,T2,R> |
spy1st(BiFunction<T1,T2,R> function,
Box<T1> param1)
Proxies a binary function spying for first parameter.
|
static <T1,T2> BiPredicate<T1,T2> |
spy1st(BiPredicate<T1,T2> predicate,
Box<T1> param1)
Proxies a binary predicate spying for first parameter
|
static <T> Consumer<T> |
spy1st(Consumer<T> consumer,
Box<T> param)
Proxies a binary consumer spying for first parameter.
|
static <R,T> Function<T,R> |
spy1st(Function<T,R> function,
Box<T> param)
Proxies a function spying for parameter.
|
static <T> Predicate<T> |
spy1st(Predicate<T> predicate,
Box<T> param)
Proxies a predicate spying for parameter.
|
static <T1,T2,T3> TriConsumer<T1,T2,T3> |
spy1st(TriConsumer<T1,T2,T3> consumer,
Box<T1> param1)
Proxies a ternary consumer spying for first parameter.
|
static <T1,T2,T3,R> |
spy1st(TriFunction<T1,T2,T3,R> function,
Box<T1> param1)
Proxies a ternary function spying for first parameter.
|
static <T1,T2,T3> TriPredicate<T1,T2,T3> |
spy1st(TriPredicate<T1,T2,T3> predicate,
Box<T1> param1)
Proxies a ternary predicate spying for first parameter.
|
static <T1,T2> BiConsumer<T1,T2> |
spy2nd(BiConsumer<T1,T2> consumer,
Box<T2> param2)
Proxies a binary consumer spying for second parameter.
|
static <T1,T2,R> BiFunction<T1,T2,R> |
spy2nd(BiFunction<T1,T2,R> function,
Box<T2> param2)
Proxies a binary function spying for second parameter.
|
static <T1,T2> BiPredicate<T1,T2> |
spy2nd(BiPredicate<T1,T2> predicate,
Box<T2> param2)
Proxies a binary predicate spying for second parameter.
|
static <T1,T2,T3> TriConsumer<T1,T2,T3> |
spy2nd(TriConsumer<T1,T2,T3> consumer,
Box<T2> param2)
Proxies a ternary consumer spying for second parameter.
|
static <T1,T2,T3,R> |
spy2nd(TriFunction<T1,T2,T3,R> function,
Box<T2> param2)
Proxies a ternary function spying for second parameter
|
static <T1,T2,T3> TriPredicate<T1,T2,T3> |
spy2nd(TriPredicate<T1,T2,T3> predicate,
Box<T2> param2)
Proxies a ternary predicate spying for second parameter.
|
static <T1,T2,T3> TriConsumer<T1,T2,T3> |
spy3rd(TriConsumer<T1,T2,T3> consumer,
Box<T3> param3)
Proxies a ternary consumer spying for third parameter.
|
static <T1,T2,T3,R> |
spy3rd(TriFunction<T1,T2,T3,R> function,
Box<T3> param3)
Proxies a ternary function spying for third parameter.
|
static <T1,T2,T3> TriPredicate<T1,T2,T3> |
spy3rd(TriPredicate<T1,T2,T3> predicate,
Box<T3> param3)
Proxies a ternary predicate spying for third parameter.
|
static <T1,T2,R> BiFunction<T1,T2,R> |
spyRes(BiFunction<T1,T2,R> function,
Box<R> result)
Proxies a binary function spying for result.
|
static <T1,T2> BiPredicate<T1,T2> |
spyRes(BiPredicate<T1,T2> predicate,
Box<Boolean> result)
Proxies a binary predicate spying for result.
|
static <R,T> Function<T,R> |
spyRes(Function<T,R> function,
Box<R> result)
Proxies a function spying for result.
|
static <T> Predicate<T> |
spyRes(Predicate<T> predicate,
Box<Boolean> result)
Proxies a predicate spying for result.
|
static <T1,T2,T3,R> |
spyRes(TriFunction<T1,T2,T3,R> function,
Box<R> result)
Proxies a ternary function spying for result.
|
static <T1,T2,T3> TriPredicate<T1,T2,T3> |
spyRes(TriPredicate<T1,T2,T3> predicate,
Box<Boolean> result)
Proxies a ternary predicate spying for result.
|
public static BooleanSupplier spy(BooleanSupplier proposition, Box<Boolean> result)
proposition - the proposition to be spiedresult - a box that will be containing spied resultpublic static <R> Supplier<R> spy(Supplier<R> supplier, Box<R> result)
R - the supplier result typesupplier - the supplier to be spiedresult - a box that will be containing spied resultpublic static <T,R> Function<T,R> spy(Function<T,R> function, Box<R> result, Box<T> param)
T - the function parameter typeR - the function result typefunction - the function to be spiedresult - a box that will be containing spied resultparam - a box that will be containing spied parampublic static <T1,T2,R> BiFunction<T1,T2,R> spy(BiFunction<T1,T2,R> function, Box<R> result, Box<T1> param1, Box<T2> param2)
T1 - the function first parameter typeT2 - the function second parameter typeR - the function result typefunction - the function to be spiedresult - a box that will be containing spied resultparam1 - a box that will be containing the first spied parameterparam2 - a box that will be containing the second spied parameterpublic static <T1,T2,T3,R> TriFunction<T1,T2,T3,R> spy(TriFunction<T1,T2,T3,R> function, Box<R> result, Box<T1> param1, Box<T2> param2, Box<T3> param3)
R - the function result typeT1 - the function first parameter typeT2 - the function second parameter typeT3 - the function third parameter typefunction - the function to be spiedresult - a box that will be containing spied resultparam1 - a box that will be containing the first spied parameterparam2 - a box that will be containing the second spied parameterparam3 - a box that will be containing the third spied parameterpublic static <T> Predicate<T> spy(Predicate<T> predicate, Box<Boolean> result, Box<T> param)
T - the predicate parameter typepredicate - the predicateto be spiedresult - a box that will be containing spied resultparam - a box that will be containing the spied parameterpublic static <T1,T2> BiPredicate<T1,T2> spy(BiPredicate<T1,T2> predicate, Box<Boolean> result, Box<T1> param1, Box<T2> param2)
T1 - the predicate first parameter typeT2 - the predicate second parameter typepredicate - the predicate to be spiedresult - a box that will be containing spied resultparam1 - a box that will be containing the first spied parameterparam2 - a box that will be containing the second spied parameterpublic static <T1,T2,T3> TriPredicate<T1,T2,T3> spy(TriPredicate<T1,T2,T3> predicate, Box<Boolean> result, Box<T1> param1, Box<T2> param2, Box<T3> param3)
T1 - the predicate first parameter typeT2 - the predicate second parameter typeT3 - the predicate third parameter typepredicate - the predicate to be spiedresult - a box that will be containing spied resultparam1 - a box that will be containing the first spied parameterparam2 - a box that will be containing the second spied parameterparam3 - a box that will be containing the third spied parameterpublic static <T> Consumer<T> spy(Consumer<T> consumer, Box<T> param)
T - the consumer parameter typeconsumer - the consumer to be spiedparam - a box that will be containing the spied parameterpublic static <T1,T2> BiConsumer<T1,T2> spy(BiConsumer<T1,T2> consumer, Box<T1> param1, Box<T2> param2)
T1 - the consumer first parameter typeT2 - the consumer second parameter typeconsumer - the consumer that will be spiedparam1 - a box that will be containing the first spied parameterparam2 - a box that will be containing the second spied parameterpublic static <T1,T2,T3> TriConsumer<T1,T2,T3> spy(TriConsumer<T1,T2,T3> consumer, Box<T1> param1, Box<T2> param2, Box<T3> param3)
T1 - the consumer first parameter typeT2 - the consumer second parameter typeT3 - the consumer third parameter typeconsumer - the consumer that will be spiedparam1 - a box that will be containing the first spied parameterparam2 - a box that will be containing the second spied parameterparam3 - a box that will be containing the third spied parameterpublic static <T1,T2,T3,R> TriFunction<T1,T2,T3,R> spyRes(TriFunction<T1,T2,T3,R> function, Box<R> result)
R - the function result typeT1 - the function first parameter typeT2 - the function second parameter typeT3 - the function third parameter typefunction - the function that will be spiedresult - a box that will be containing spied resultpublic static <T1,T2,T3,R> TriFunction<T1,T2,T3,R> spy1st(TriFunction<T1,T2,T3,R> function, Box<T1> param1)
R - the function result typeT1 - the function first parameter typeT2 - the function second parameter typeT3 - the function third parameter typefunction - the function that will be spiedparam1 - a box that will be containing the first spied parameterpublic static <T1,T2,T3,R> TriFunction<T1,T2,T3,R> spy2nd(TriFunction<T1,T2,T3,R> function, Box<T2> param2)
R - the function result typeT1 - the function first parameter typeT2 - the function second parameter typeT3 - the function third parameter typefunction - the function that will be spiedparam2 - a box that will be containing the second spied parameterpublic static <T1,T2,T3,R> TriFunction<T1,T2,T3,R> spy3rd(TriFunction<T1,T2,T3,R> function, Box<T3> param3)
R - the function result typeT1 - the function first parameter typeT2 - the function second parameter typeT3 - the function third parameter typefunction - the function that will be spiedparam3 - a box that will be containing the third spied parameterpublic static <T1,T2,R> BiFunction<T1,T2,R> spyRes(BiFunction<T1,T2,R> function, Box<R> result)
T1 - the function first parameter typeT2 - the function second parameter typeR - the function result typefunction - the function that will be spiedresult - a box that will be containing spied resultpublic static <T1,T2,R> BiFunction<T1,T2,R> spy1st(BiFunction<T1,T2,R> function, Box<T1> param1)
T1 - the function first parameter typeT2 - the function second parameter typeR - the function result typefunction - the function that will be spiedparam1 - a box that will be containing the first spied parameterpublic static <T1,T2,R> BiFunction<T1,T2,R> spy2nd(BiFunction<T1,T2,R> function, Box<T2> param2)
T1 - the function first parameter typeT2 - the function second parameter typeR - the function result typefunction - the function that will be spiedparam2 - a box that will be containing the second spied parameterpublic static <R,T> Function<T,R> spyRes(Function<T,R> function, Box<R> result)
R - the function result typeT - the function parameter typefunction - the function that will be spiedresult - a box that will be containing spied resultpublic static <R,T> Function<T,R> spy1st(Function<T,R> function, Box<T> param)
R - the function result typeT - the function parameter typefunction - the function that will be spiedparam - a box that will be containing spied parameterpublic static <T1,T2,T3> TriConsumer<T1,T2,T3> spy1st(TriConsumer<T1,T2,T3> consumer, Box<T1> param1)
T1 - the consumer first parameter typeT2 - the consumer second parameter typeT3 - the consumer third parameter typeconsumer - the consumer that will be spiedparam1 - a box that will be containing the first spied parameterpublic static <T1,T2,T3> TriConsumer<T1,T2,T3> spy2nd(TriConsumer<T1,T2,T3> consumer, Box<T2> param2)
T1 - the consumer first parameter typeT2 - the consumer second parameter typeT3 - the consumer third parameter typeconsumer - the consumer that will be spiedparam2 - a box that will be containing the second spied parameterpublic static <T1,T2,T3> TriConsumer<T1,T2,T3> spy3rd(TriConsumer<T1,T2,T3> consumer, Box<T3> param3)
T1 - the consumer first parameter typeT2 - the consumer second parameter typeT3 - the consumer third parameter typeconsumer - the consumer that will be spiedparam3 - a box that will be containing the third spied parameterpublic static <T1,T2> BiConsumer<T1,T2> spy1st(BiConsumer<T1,T2> consumer, Box<T1> param1)
T1 - the consumer first parameter typeT2 - the consumer second parameter typeconsumer - the consumer that will be spiedparam1 - a box that will be containing the first spied parameterpublic static <T1,T2> BiConsumer<T1,T2> spy2nd(BiConsumer<T1,T2> consumer, Box<T2> param2)
T1 - the consumer first parameter typeT2 - the consumer second parameter typeconsumer - the consumer that will be spiedparam2 - a box that will be containing the second spied parameterpublic static <T> Consumer<T> spy1st(Consumer<T> consumer, Box<T> param)
T - the consumer parameter typeconsumer - the consumer that will be spiedparam - a box that will be containing the spied parameterpublic static <T1,T2,T3> TriPredicate<T1,T2,T3> spyRes(TriPredicate<T1,T2,T3> predicate, Box<Boolean> result)
T1 - the predicate first parameter typeT2 - the predicate second parameter typeT3 - the predicate third parameter typepredicate - the predicate that will be spiedresult - a box that will be containing spied resultpublic static <T1,T2,T3> TriPredicate<T1,T2,T3> spy1st(TriPredicate<T1,T2,T3> predicate, Box<T1> param1)
T1 - the predicate first parameter typeT2 - the predicate second parameter typeT3 - the predicate third parameter typepredicate - the predicate that will be spiedparam1 - a box that will be containing the first spied parameterpublic static <T1,T2,T3> TriPredicate<T1,T2,T3> spy2nd(TriPredicate<T1,T2,T3> predicate, Box<T2> param2)
T1 - the predicate first parameter typeT2 - the predicate second parameter typeT3 - the predicate third parameter typepredicate - the predicate that will be spiedparam2 - a box that will be containing the second spied parameterpublic static <T1,T2,T3> TriPredicate<T1,T2,T3> spy3rd(TriPredicate<T1,T2,T3> predicate, Box<T3> param3)
T1 - the predicate first parameter typeT2 - the predicate second parameter typeT3 - the predicate third parameter typepredicate - the predicate that will be spiedparam3 - a box that will be containing the third spied parameterpublic static <T1,T2> BiPredicate<T1,T2> spyRes(BiPredicate<T1,T2> predicate, Box<Boolean> result)
T1 - the predicate first parameter typeT2 - the predicate second parameter typepredicate - the predicate that will be spiedresult - a box that will be containing spied resultpublic static <T1,T2> BiPredicate<T1,T2> spy1st(BiPredicate<T1,T2> predicate, Box<T1> param1)
T1 - the predicate first parameter typeT2 - the predicate second parameter typepredicate - the predicate that will be spiedparam1 - a box that will be containing the first spied parameterpublic static <T1,T2> BiPredicate<T1,T2> spy2nd(BiPredicate<T1,T2> predicate, Box<T2> param2)
T1 - the predicate first parameter typeT2 - the predicate second parameter typepredicate - the predicate that will be spiedparam2 - a box that will be containing the second spied parameterpublic static <T> Predicate<T> spyRes(Predicate<T> predicate, Box<Boolean> result)
T - the predicate parameter typepredicate - the predicate that will be spiedresult - a box that will be containing spied resultpublic static <T> Predicate<T> spy1st(Predicate<T> predicate, Box<T> param)
T - the predicate parameter typepredicate - the predicate that will be spiedparam - a box that will be containing spied parameterpublic static <T> Consumer<T> monitor(Consumer<T> consumer, AtomicLong calls)
T - the consumer parameter typeconsumer - the consumer that will be monitoredcalls - a value holder accumulating callspublic static <T,R> Function<T,R> monitor(Function<T,R> function, AtomicLong calls)
T - the function parameter typeR - the function result typefunction - the function that will be monitoredcalls - a value holder accumulating callspublic static <T> Predicate<T> monitor(Predicate<T> predicate, AtomicLong calls)
T - the predicate parameter typepredicate - the predicate that will be monitoredcalls - a value holder accumulating callspublic static BooleanSupplier monitor(BooleanSupplier proposition, AtomicLong calls)
proposition - the proposition that will be monitoredcalls - a value holder accumulating callspublic static <R> Supplier<R> monitor(Supplier<R> supplier, AtomicLong calls)
R - the supplier result typesupplier - the supplier that will be monitoredcalls - a value holder accumulating callspublic static Runnable monitor(Runnable runnable, AtomicLong calls)
runnable - the runnable that will be monitoredcalls - a value holder accumulating callspublic static <T1,T2> BiConsumer<T1,T2> monitor(BiConsumer<T1,T2> consumer, AtomicLong calls)
T1 - the consumer first parameter typeT2 - the consumer second parameter typeconsumer - the consumer that will be monitoredcalls - a value holder accumulating callspublic static <T1,T2,R> BiFunction<T1,T2,R> monitor(BiFunction<T1,T2,R> function, AtomicLong calls)
T1 - the function first parameter typeT2 - the function second parameter typeR - the function result typefunction - the function that will be monitoredcalls - a value holder accumulating callspublic static <T1,T2> BiPredicate<T1,T2> monitor(BiPredicate<T1,T2> predicate, AtomicLong calls)
T1 - the predicate first parameter typeT2 - the predicate second parameter typepredicate - the predicate that will be monitoredcalls - a value holder accumulating callspublic static <T1,T2,T3> TriConsumer<T1,T2,T3> monitor(TriConsumer<T1,T2,T3> consumer, AtomicLong calls)
T1 - the consumer first parameter typeT2 - the consumer second parameter typeT3 - the consumer third parameter typeconsumer - the consumer that will be monitoredcalls - a value holder accumulating callspublic static <T1,T2,T3,R> TriFunction<T1,T2,T3,R> monitor(TriFunction<T1,T2,T3,R> function, AtomicLong calls)
R - the function result typeT1 - the function first parameter typeT2 - the function second parameter typeT3 - the function third parameter typefunction - the function that will be monitoredcalls - a value holder accumulating callspublic static <T1,T2,T3> TriPredicate<T1,T2,T3> monitor(TriPredicate<T1,T2,T3> predicate, AtomicLong calls)
T1 - the predicate first parameter typeT2 - the predicate second parameter typeT3 - the predicate third parameter typepredicate - the predicate that will be monitoredcalls - a value holder accumulating callsCopyright © 2017. All rights reserved.