@FunctionalInterface
public interface CharUnaryOperator
extends java.util.function.UnaryOperator<java.lang.Character>, java.util.function.IntUnaryOperator
UnaryOperator
; provides methods operating both on objects
and on primitives.UnaryOperator
Modifier and Type | Method and Description |
---|---|
char |
apply(char x)
Computes the operator on the given input.
|
default java.lang.Character |
apply(java.lang.Character x)
Deprecated.
Please use the corresponding type-specific method instead.
|
default int |
applyAsInt(int x)
Deprecated.
Please use
apply(char) . |
static CharUnaryOperator |
identity()
Returns a
UnaryOperator that always returns the input unmodified. |
char apply(char x)
x
- the input.static CharUnaryOperator identity()
UnaryOperator
that always returns the input unmodified.identity
in interface java.util.function.Function<java.lang.Character,java.lang.Character>
identity
in interface java.util.function.IntUnaryOperator
identity
in interface java.util.function.UnaryOperator<java.lang.Character>
UnaryOperator.identity()
@Deprecated default int applyAsInt(int x)
apply(char)
.applyAsInt
in interface java.util.function.IntUnaryOperator
java.lang.IllegalArgumentException
- If the given operands are not an element of the key domain.apply(char)
after narrowing down the argument to the
actual key type, throwing an exception if the argument cannot be
represented in the restricted domain. This is done for interoperability
with the Java 8 function environment. The use of this method discouraged, as
unexpected errors can occur.@Deprecated default java.lang.Character apply(java.lang.Character x)
apply
in interface java.util.function.Function<java.lang.Character,java.lang.Character>