Top Description Fields Constructors Methods
net.bytebuddy.implementation.bytecode.assign.reference

public final Enum ReferenceTypeAwareAssigner

extends Enum<ReferenceTypeAwareAssigner>
implements Assigner
Class Inheritance
All Implemented Interfaces
net.bytebuddy.implementation.bytecode.assign.Assigner
Imports
net.bytebuddy.description.type.TypeDescription, net.bytebuddy.implementation.bytecode.StackManipulation, net.bytebuddy.implementation.bytecode.assign.Assigner, .TypeCasting

A simple assigner that is capable of handling the casting of reference types. Primitives can only be assigned to each other if they represent the same type.

Field Summary

Modifier and TypeField and Description
public static final ReferenceTypeAwareAssigner
INSTANCE

The singleton instance.

Constructor Summary

AccessConstructor and Description
private

Method Summary

Modifier and TypeMethod and Description
public StackManipulation
assign(TypeDescription.Generic
The original type that is to be transformed into the targetType.
source
,
TypeDescription.Generic
The target type into which the sourceType is to be converted.
target
,
Assigner.Typing
A hint whether the assignment should consider the runtime type of the source type, i.e. if type down or cross castings are allowed. If this hint is set, this is also an indication that void to non-void assignments are permitted.
typing
)

Implements net.bytebuddy.implementation.bytecode.assign.Assigner.assign.

public static ReferenceTypeAwareAssigner
public static ReferenceTypeAwareAssigner[]
Inherited from java.lang.Enum:
clonecompareTodescribeConstableequalsfinalizegetDeclaringClasshashCodenameordinaltoStringvalueOf

Field Detail

INSTANCEback to summary
public static final ReferenceTypeAwareAssigner INSTANCE

The singleton instance.

Constructor Detail

ReferenceTypeAwareAssignerback to summary
private ReferenceTypeAwareAssigner()

Method Detail

assignback to summary
public StackManipulation assign(TypeDescription.Generic source, TypeDescription.Generic target, Assigner.Typing typing)

Implements net.bytebuddy.implementation.bytecode.assign.Assigner.assign.

Parameters
source:TypeDescription.Generic

Doc from net.bytebuddy.implementation.bytecode.assign.Assigner.assign.

The original type that is to be transformed into the targetType.

target:TypeDescription.Generic

Doc from net.bytebuddy.implementation.bytecode.assign.Assigner.assign.

The target type into which the sourceType is to be converted.

typing:Assigner.Typing

Doc from net.bytebuddy.implementation.bytecode.assign.Assigner.assign.

A hint whether the assignment should consider the runtime type of the source type, i.e. if type down or cross castings are allowed. If this hint is set, this is also an indication that void to non-void assignments are permitted.

Returns:StackManipulation

Doc from net.bytebuddy.implementation.bytecode.assign.Assigner.assign.

A stack manipulation that transforms the sourceType into the targetType if this is possible. An illegal stack manipulation otherwise.

valueOfback to summary
public static ReferenceTypeAwareAssigner valueOf(String name)
valuesback to summary
public static ReferenceTypeAwareAssigner[] values()