Enum PrimitiveUnboxingDelegate.ExplicitlyTypedUnboxingResponsible
java.lang.Object
java.lang.Enum<PrimitiveUnboxingDelegate.ExplicitlyTypedUnboxingResponsible>
net.bytebuddy.implementation.bytecode.assign.primitive.PrimitiveUnboxingDelegate.ExplicitlyTypedUnboxingResponsible
- All Implemented Interfaces:
Serializable
,Comparable<PrimitiveUnboxingDelegate.ExplicitlyTypedUnboxingResponsible>
,java.lang.constant.Constable
,PrimitiveUnboxingDelegate.UnboxingResponsible
- Enclosing class:
PrimitiveUnboxingDelegate
protected static enum PrimitiveUnboxingDelegate.ExplicitlyTypedUnboxingResponsible
extends Enum<PrimitiveUnboxingDelegate.ExplicitlyTypedUnboxingResponsible>
implements PrimitiveUnboxingDelegate.UnboxingResponsible
An explicitly types unboxing responsible is applied for directly unboxing a wrapper type.
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionAn unboxing responsible for unboxing aBoolean
type.An unboxing responsible for unboxing aByte
type.An unboxing responsible for unboxing aCharacter
type.An unboxing responsible for unboxing aDouble
type.An unboxing responsible for unboxing aFloat
type.An unboxing responsible for unboxing aInteger
type.An unboxing responsible for unboxing aLong
type.An unboxing responsible for unboxing aShort
type. -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final PrimitiveUnboxingDelegate
The primitive unboxing delegate for handling the given wrapper type. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivate
ExplicitlyTypedUnboxingResponsible
(PrimitiveUnboxingDelegate primitiveUnboxingDelegate) Creates a new explicitly typed unboxing responsible. -
Method Summary
Modifier and TypeMethodDescriptionassignUnboxedTo
(TypeDescription.Generic targetType, Assigner assigner, Assigner.Typing typing) Attempts to unbox the represented type in order to assign the unboxed value to the given target type while using the assigner that is provided by the method call.Returns the enum constant of this type with the specified name.values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
BOOLEAN
An unboxing responsible for unboxing aBoolean
type. -
BYTE
An unboxing responsible for unboxing aByte
type. -
SHORT
An unboxing responsible for unboxing aShort
type. -
CHARACTER
An unboxing responsible for unboxing aCharacter
type. -
INTEGER
An unboxing responsible for unboxing aInteger
type. -
LONG
An unboxing responsible for unboxing aLong
type. -
FLOAT
An unboxing responsible for unboxing aFloat
type. -
DOUBLE
An unboxing responsible for unboxing aDouble
type.
-
-
Field Details
-
primitiveUnboxingDelegate
The primitive unboxing delegate for handling the given wrapper type.
-
-
Constructor Details
-
ExplicitlyTypedUnboxingResponsible
Creates a new explicitly typed unboxing responsible.- Parameters:
primitiveUnboxingDelegate
- The primitive unboxing delegate for handling the given wrapper type.
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
assignUnboxedTo
public StackManipulation assignUnboxedTo(TypeDescription.Generic targetType, Assigner assigner, Assigner.Typing typing) Attempts to unbox the represented type in order to assign the unboxed value to the given target type while using the assigner that is provided by the method call.- Specified by:
assignUnboxedTo
in interfacePrimitiveUnboxingDelegate.UnboxingResponsible
- Parameters:
targetType
- The type that is the desired outcome of the assignment.assigner
- The assigner used to assign the unboxed type to the target type.typing
- Determines if a type-casting should be attempted for incompatible types.- Returns:
- A stack manipulation representing this assignment if such an assignment is possible. An illegal assignment otherwise.
-