@FunctionalInterface public interface LDblUnaryOperator extends java.util.function.DoubleUnaryOperator, MetaOperator, MetaInterface.NonThrowing, Codomain<aType.aDouble>, Domain1<aType.aDouble>
Non-throwing functional interface (lambda) LDblUnaryOperator for Java 8.
Type: operator
Domain (lvl: 1): double a
Co-domain: double
| Modifier and Type | Interface and Description |
|---|---|
static class |
LDblUnaryOperator.LDblUnaryOperatorSingle |
MetaInterface.NonThrowing, MetaInterface.Throwing<X>| Modifier and Type | Field and Description |
|---|---|
static String |
DESCRIPTION |
| Modifier and Type | Method and Description |
|---|---|
default double |
applyAsDbl(double a) |
default double |
applyAsDbl(double a,
ExWF<RuntimeException> exF) |
default double |
applyAsDbl(double a,
ExWMF<RuntimeException> exF,
String newMessage,
Object... messageParams) |
default double |
applyAsDblThen(double a,
LToDblFunction<Throwable> handler) |
double |
applyAsDblX(double a)
Implement this, but call applyAsDbl(double a)
|
default double |
applyAsDouble(double a)
Deprecated.
Calling this method via LDblUnaryOperator interface should be discouraged.
|
static double |
call(double a,
LDblUnaryOperator lambda) |
default LDblSupplier |
capture(double a)
Captures arguments but delays the evaluation.
|
default LDblUnaryOperator |
compose(LDblUnaryOperator before)
Allows to manipulate the domain of the function.
|
static LDblUnaryOperator |
composed(LDblUnaryOperator before,
LDblUnaryOperator after) |
static <V> LToDblFunction<V> |
composed(LToDblFunction<? super V> before,
LDblUnaryOperator after) |
static LDblUnaryOperator |
constant(double r)
Creates function that always returns the same value.
|
static LDblUnaryOperator |
dblUnaryOp(LDblUnaryOperator lambda)
Convenient method in case lambda expression is ambiguous for the compiler (that might happen for overloaded methods accepting different interfaces).
|
default <V> LToDblFunction<V> |
dblUnaryOpCompose(LToDblFunction<? super V> before)
Allows to manipulate the domain of the function.
|
static LDblUnaryOperator |
dblUnaryOpThrowing(ExF<Throwable> exF) |
static LDblUnaryOperator |
dblUnaryOpThrowing(String message,
ExMF<Throwable> exF) |
static LDblUnaryOperator |
failSafe(LDblUnaryOperator func,
LDblUnaryOperator failSafe) |
default double |
failSafeApplyAsDbl(double a,
LDblUnaryOperator failSafe) |
static double |
failSafeApplyAsDbl(double a,
LDblUnaryOperator func,
LDblUnaryOperator failSafe) |
default <C0> void |
forEach(IndexedRead<C0,aType.aDouble> ia,
C0 source,
LDblConsumer consumer)
For each element (or tuple) from arguments, calls the function and passes the result to consumer.
|
static void |
fromTill(int min_i,
int max_i,
double a,
LDblUnaryOperator func)
From-To.
|
static void |
fromTo(int min_i,
int max_i,
double a,
LDblUnaryOperator func)
From-To.
|
default String |
functionalInterfaceDescription()
Returns description of the functional interface.
|
default LDblUnaryOperator |
handling(HandlingInstructions<Throwable,RuntimeException> handling) |
default double |
handlingApplyAsDbl(double a,
HandlingInstructions<Throwable,RuntimeException> handling)
Function call that handles exceptions according to the instructions.
|
static double |
handlingApplyAsDbl(double a,
LDblUnaryOperator func,
HandlingInstructions<Throwable,RuntimeException> handling) |
static LDblUnaryOperator |
identity()
Returns a function that always returns its input argument.
|
default <C0,I0> void |
iterate(SequentialRead<C0,I0,aType.aDouble> sa,
C0 source,
LDblConsumer consumer)
For each element (or tuple) from arguments, calls the function and passes the result to consumer.
|
default double |
nestingApplyAsDbl(double a)
Function call that handles exceptions by always nesting checked exceptions and propagating the others as is.
|
default double |
nonNullApplyAsDbl(double a)
Just to mirror the method: Ensures the result is not null
|
static double |
produceDouble(double a)
Does nothing (LDblUnaryOperator) Operator
|
static LDblUnaryOperator |
recursive(LFunction<LDblUnaryOperator,LDblUnaryOperator> selfLambda) |
static LDblUnaryOperator |
safe()
Safe instance.
|
static LDblUnaryOperator |
safe(LDblUnaryOperator other)
Safe wrapping.
|
static LSupplier<LDblUnaryOperator> |
safeSupplier()
Safe instance supplier.
|
static LSupplier<LDblUnaryOperator> |
safeSupplier(LSupplier<LDblUnaryOperator> supplier)
Safe supplier.
|
default double |
shovingApplyAsDbl(double a)
Function call that handles exceptions by always propagating them as is, even when they are undeclared checked ones.
|
default <V> LDblFunction<V> |
then(LDblFunction<? extends V> after)
Combines two functions together in a order.
|
default LDblPredicate |
thenToBool(LDblPredicate after)
Combines two functions together in a order.
|
default LDblToByteFunction |
thenToByte(LDblToByteFunction after)
Combines two functions together in a order.
|
default LDblToCharFunction |
thenToChar(LDblToCharFunction after)
Combines two functions together in a order.
|
default LDblUnaryOperator |
thenToDbl(LDblUnaryOperator after)
Combines two functions together in a order.
|
default LDblToFltFunction |
thenToFlt(LDblToFltFunction after)
Combines two functions together in a order.
|
default LDblToIntFunction |
thenToInt(LDblToIntFunction after)
Combines two functions together in a order.
|
default LDblToLongFunction |
thenToLong(LDblToLongFunction after)
Combines two functions together in a order.
|
default LDblToSrtFunction |
thenToSrt(LDblToSrtFunction after)
Combines two functions together in a order.
|
static void |
times(int max_i,
double a,
LDblUnaryOperator func)
From-To.
|
static double |
tryApplyAsDbl(double a,
LDblUnaryOperator func) |
static double |
tryApplyAsDbl(double a,
LDblUnaryOperator func,
ExWF<RuntimeException> exF) |
static double |
tryApplyAsDbl(double a,
LDblUnaryOperator func,
ExWMF<RuntimeException> exF,
String newMessage,
Object... messageParams) |
static double |
tryApplyAsDblThen(double a,
LDblUnaryOperator func,
LToDblFunction<Throwable> handler) |
default LDblUnaryOperator |
trying(ExWF<RuntimeException> exF) |
default LDblUnaryOperator |
trying(ExWMF<RuntimeException> exF,
String newMessage,
Object... messageParams) |
default LDblUnaryOperator |
tryingThen(LToDblFunction<Throwable> handler) |
default double |
tupleApplyAsDbl(LDblSingle args) |
static LDblUnaryOperator |
wrap(java.util.function.DoubleUnaryOperator other)
Wraps JRE instance.
|
andThen, composeisOperatorisFunctionformatTo, isAction, isConsumer, isPredicate, isSupplierisThrowingisThrowingstatic final String DESCRIPTION
@Deprecated default double applyAsDouble(double a)
Default implementation for JRE method that calls exception nesting method.
applyAsDouble in interface java.util.function.DoubleUnaryOperatordefault double applyAsDbl(double a)
double applyAsDblX(double a)
throws Throwable
Implement this, but call applyAsDbl(double a)
Throwabledefault double tupleApplyAsDbl(LDblSingle args)
default double handlingApplyAsDbl(double a,
HandlingInstructions<Throwable,RuntimeException> handling)
Function call that handles exceptions according to the instructions.
default LDblUnaryOperator handling(HandlingInstructions<Throwable,RuntimeException> handling)
default double applyAsDbl(double a,
@Nonnull
ExWMF<RuntimeException> exF,
@Nonnull
String newMessage,
@Nullable
Object... messageParams)
default LDblUnaryOperator trying(@Nonnull ExWMF<RuntimeException> exF, @Nonnull String newMessage, @Nullable Object... messageParams)
default double applyAsDbl(double a,
@Nonnull
ExWF<RuntimeException> exF)
default LDblUnaryOperator trying(@Nonnull ExWF<RuntimeException> exF)
default double applyAsDblThen(double a,
@Nonnull
LToDblFunction<Throwable> handler)
default LDblUnaryOperator tryingThen(@Nonnull LToDblFunction<Throwable> handler)
default double nestingApplyAsDbl(double a)
Function call that handles exceptions by always nesting checked exceptions and propagating the others as is.
default double shovingApplyAsDbl(double a)
Function call that handles exceptions by always propagating them as is, even when they are undeclared checked ones.
static double handlingApplyAsDbl(double a,
LDblUnaryOperator func,
HandlingInstructions<Throwable,RuntimeException> handling)
static double tryApplyAsDbl(double a,
LDblUnaryOperator func)
static double tryApplyAsDbl(double a,
LDblUnaryOperator func,
@Nonnull
ExWMF<RuntimeException> exF,
@Nonnull
String newMessage,
@Nullable
Object... messageParams)
static double tryApplyAsDbl(double a,
LDblUnaryOperator func,
@Nonnull
ExWF<RuntimeException> exF)
static double tryApplyAsDblThen(double a,
LDblUnaryOperator func,
@Nonnull
LToDblFunction<Throwable> handler)
default double failSafeApplyAsDbl(double a,
@Nonnull
LDblUnaryOperator failSafe)
static double failSafeApplyAsDbl(double a,
LDblUnaryOperator func,
@Nonnull
LDblUnaryOperator failSafe)
static LDblUnaryOperator failSafe(LDblUnaryOperator func, @Nonnull LDblUnaryOperator failSafe)
default double nonNullApplyAsDbl(double a)
Just to mirror the method: Ensures the result is not null
@Nonnull default String functionalInterfaceDescription()
Returns description of the functional interface.
functionalInterfaceDescription in interface MetaFunctionalInterfacestatic void fromTo(int min_i,
int max_i,
double a,
LDblUnaryOperator func)
From-To. Intended to be used with non-capturing lambda.
static void fromTill(int min_i,
int max_i,
double a,
LDblUnaryOperator func)
From-To. Intended to be used with non-capturing lambda.
static void times(int max_i,
double a,
LDblUnaryOperator func)
From-To. Intended to be used with non-capturing lambda.
default LDblSupplier capture(double a)
Captures arguments but delays the evaluation.
static LDblUnaryOperator constant(double r)
Creates function that always returns the same value.
@Nonnull static LDblUnaryOperator dblUnaryOp(@Nonnull LDblUnaryOperator lambda)
Convenient method in case lambda expression is ambiguous for the compiler (that might happen for overloaded methods accepting different interfaces).
@Nonnull static LDblUnaryOperator recursive(@Nonnull LFunction<LDblUnaryOperator,LDblUnaryOperator> selfLambda)
@Nonnull static LDblUnaryOperator dblUnaryOpThrowing(@Nonnull ExF<Throwable> exF)
@Nonnull static LDblUnaryOperator dblUnaryOpThrowing(String message, @Nonnull ExMF<Throwable> exF)
static double call(double a,
@Nonnull
LDblUnaryOperator lambda)
@Nonnull static LDblUnaryOperator wrap(java.util.function.DoubleUnaryOperator other)
Wraps JRE instance.
@Nonnull static LDblUnaryOperator safe()
Safe instance. That always returns the same value (as produceDouble).
@Nonnull static LSupplier<LDblUnaryOperator> safeSupplier()
Safe instance supplier. Returns supplier of safe() instance.
@Nonnull static LDblUnaryOperator safe(@Nullable LDblUnaryOperator other)
Safe wrapping. Either argument function is returned (if it is not null) or safe() instance.
@Nonnull static LSupplier<LDblUnaryOperator> safeSupplier(@Nullable LSupplier<LDblUnaryOperator> supplier)
Safe supplier. Either argument supplier is returned (if it is not null) or supplier of safe() instance.
@Nonnull default LDblUnaryOperator compose(@Nonnull LDblUnaryOperator before)
Allows to manipulate the domain of the function.
static LDblUnaryOperator composed(@Nonnull LDblUnaryOperator before, LDblUnaryOperator after)
@Nonnull default <V> LToDblFunction<V> dblUnaryOpCompose(@Nonnull LToDblFunction<? super V> before)
Allows to manipulate the domain of the function.
static <V> LToDblFunction<V> composed(@Nonnull LToDblFunction<? super V> before, LDblUnaryOperator after)
@Nonnull default <V> LDblFunction<V> then(@Nonnull LDblFunction<? extends V> after)
Combines two functions together in a order.
@Nonnull default LDblToByteFunction thenToByte(@Nonnull LDblToByteFunction after)
Combines two functions together in a order.
@Nonnull default LDblToSrtFunction thenToSrt(@Nonnull LDblToSrtFunction after)
Combines two functions together in a order.
@Nonnull default LDblToIntFunction thenToInt(@Nonnull LDblToIntFunction after)
Combines two functions together in a order.
@Nonnull default LDblToLongFunction thenToLong(@Nonnull LDblToLongFunction after)
Combines two functions together in a order.
@Nonnull default LDblToFltFunction thenToFlt(@Nonnull LDblToFltFunction after)
Combines two functions together in a order.
@Nonnull default LDblUnaryOperator thenToDbl(@Nonnull LDblUnaryOperator after)
Combines two functions together in a order.
@Nonnull default LDblToCharFunction thenToChar(@Nonnull LDblToCharFunction after)
Combines two functions together in a order.
@Nonnull default LDblPredicate thenToBool(@Nonnull LDblPredicate after)
Combines two functions together in a order.
@Nonnull static LDblUnaryOperator identity()
Returns a function that always returns its input argument.
identity in interface java.util.function.DoubleUnaryOperatorstatic double produceDouble(double a)
Does nothing (LDblUnaryOperator) Operator
default <C0> void forEach(IndexedRead<C0,aType.aDouble> ia, C0 source, LDblConsumer consumer)
For each element (or tuple) from arguments, calls the function and passes the result to consumer. Thread safety, fail-fast, fail-safety of this method is not expected.
default <C0,I0> void iterate(SequentialRead<C0,I0,aType.aDouble> sa, C0 source, LDblConsumer consumer)
For each element (or tuple) from arguments, calls the function and passes the result to consumer. Thread safety, fail-fast, fail-safety of this method depends highly on the arguments.
Copyright © 2019. All rights reserved.