public enum MethodVariableAccess extends Enum<MethodVariableAccess>
Modifier and Type | Class and Description |
---|---|
protected class |
MethodVariableAccess.ArgumentLoadingStackManipulation
A stack manipulation for loading a variable of a method's local variable array onto the operand stack.
|
protected static interface |
MethodVariableAccess.TypeCastingHandler
A handler for optionally applying a type casting for each method parameter that is loaded onto the operand
stack.
|
Enum Constant and Description |
---|
DOUBLE
The accessor handler for a
double . |
FLOAT
The accessor handler for a
float . |
INTEGER
The accessor handler for a JVM-integer.
|
LONG
The accessor handler for a
long . |
REFERENCE
The accessor handler for a reference type.
|
Modifier and Type | Method and Description |
---|---|
static StackManipulation |
forBridgeMethodInvocation(MethodDescription bridgeMethod,
MethodDescription targetMethod)
Creates a stack manipulation for loading all parameters of a Java bridge method onto the operand stack where
all variables of the bridge method are casted to the parameter types of the target method.
|
static MethodVariableAccess |
forType(TypeDescription typeDescription)
Locates the correct accessor for a variable of a given type.
|
static StackManipulation |
loadArguments(MethodDescription methodDescription)
Loads all method arguments for a given method onto the operand stack.
|
StackManipulation |
loadOffset(int variableOffset)
Creates a stack assignment for a given index of the local variable array.
|
static StackManipulation |
loadThisReferenceAndArguments(MethodDescription methodDescription)
Loads all method arguments for a given method onto the operand stack, including a reference to
this ,
if the method is non-static. |
String |
toString() |
static MethodVariableAccess |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static MethodVariableAccess[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final MethodVariableAccess INTEGER
public static final MethodVariableAccess LONG
long
.public static final MethodVariableAccess FLOAT
float
.public static final MethodVariableAccess DOUBLE
double
.public static final MethodVariableAccess REFERENCE
public static MethodVariableAccess[] values()
for (MethodVariableAccess c : MethodVariableAccess.values()) System.out.println(c);
public static MethodVariableAccess valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic static MethodVariableAccess forType(TypeDescription typeDescription)
typeDescription
- The type of the variable to be loaded.public static StackManipulation loadThisReferenceAndArguments(MethodDescription methodDescription)
this
,
if the method is non-static.methodDescription
- The method for which all method arguments should be loaded onto the stack, including
a reference to this
if the method is non-static.public static StackManipulation loadArguments(MethodDescription methodDescription)
methodDescription
- The method for which all method arguments should be loaded onto the stack.public static StackManipulation forBridgeMethodInvocation(MethodDescription bridgeMethod, MethodDescription targetMethod)
this
reference onto the operand stack.bridgeMethod
- The bridge method that is invoking its target method.targetMethod
- The target of the bridge method.public StackManipulation loadOffset(int variableOffset)
The index has to be relative to the method's local variable array size.
variableOffset
- The offset of the variable where double
and long
types
count two slots.public String toString()
toString
in class Enum<MethodVariableAccess>
Copyright © 2014–2015. All rights reserved.