Package net.bytebuddy.implementation
Class InvokeDynamic.InvocationProvider.Target.ForMethodDescription
- java.lang.Object
-
- net.bytebuddy.implementation.InvokeDynamic.InvocationProvider.Target.ForMethodDescription
-
- All Implemented Interfaces:
InvokeDynamic.InvocationProvider.Target,InvokeDynamic.InvocationProvider.Target.Resolved
- Enclosing interface:
- InvokeDynamic.InvocationProvider.Target
public static class InvokeDynamic.InvocationProvider.Target.ForMethodDescription extends java.lang.Object implements InvokeDynamic.InvocationProvider.Target, InvokeDynamic.InvocationProvider.Target.Resolved
A target that requests to dynamically invoke a method to substitute for a given method.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface net.bytebuddy.implementation.InvokeDynamic.InvocationProvider.Target
InvokeDynamic.InvocationProvider.Target.ForMethodDescription, InvokeDynamic.InvocationProvider.Target.Resolved
-
Nested classes/interfaces inherited from interface net.bytebuddy.implementation.InvokeDynamic.InvocationProvider.Target.Resolved
InvokeDynamic.InvocationProvider.Target.Resolved.Simple
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedForMethodDescription(MethodDescription.InDefinedShape methodDescription)Creates a new target for substituting a given method.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetInternalName()Returns the internal name of the requested method.java.util.List<TypeDescription>getParameterTypes()Returns the types of the values on the operand stack.TypeDescriptiongetReturnType()Returns the requested return type.StackManipulationgetStackManipulation()Returns the stack manipulation that loads the arguments onto the operand stack.InvokeDynamic.InvocationProvider.Target.Resolvedresolve(TypeDescription instrumentedType, Assigner assigner, Assigner.Typing typing)Resolves the target.
-
-
-
Constructor Detail
-
ForMethodDescription
protected ForMethodDescription(MethodDescription.InDefinedShape methodDescription)
Creates a new target for substituting a given method.- Parameters:
methodDescription- The method that is being substituted.
-
-
Method Detail
-
resolve
public InvokeDynamic.InvocationProvider.Target.Resolved resolve(TypeDescription instrumentedType, Assigner assigner, Assigner.Typing typing)
Description copied from interface:InvokeDynamic.InvocationProvider.TargetResolves the target.- Specified by:
resolvein interfaceInvokeDynamic.InvocationProvider.Target- Parameters:
instrumentedType- The instrumented type.assigner- The assigner to be used.typing- Indicates if dynamic type castings should be attempted for incompatible assignments.- Returns:
- The resolved target.
-
getInternalName
public java.lang.String getInternalName()
Description copied from interface:InvokeDynamic.InvocationProvider.Target.ResolvedReturns the internal name of the requested method.- Specified by:
getInternalNamein interfaceInvokeDynamic.InvocationProvider.Target.Resolved- Returns:
- The internal name of the requested method.
-
getReturnType
public TypeDescription getReturnType()
Description copied from interface:InvokeDynamic.InvocationProvider.Target.ResolvedReturns the requested return type.- Specified by:
getReturnTypein interfaceInvokeDynamic.InvocationProvider.Target.Resolved- Returns:
- The requested return type.
-
getStackManipulation
public StackManipulation getStackManipulation()
Description copied from interface:InvokeDynamic.InvocationProvider.Target.ResolvedReturns the stack manipulation that loads the arguments onto the operand stack.- Specified by:
getStackManipulationin interfaceInvokeDynamic.InvocationProvider.Target.Resolved- Returns:
- The stack manipulation that loads the arguments onto the operand stack.
-
getParameterTypes
public java.util.List<TypeDescription> getParameterTypes()
Description copied from interface:InvokeDynamic.InvocationProvider.Target.ResolvedReturns the types of the values on the operand stack.- Specified by:
getParameterTypesin interfaceInvokeDynamic.InvocationProvider.Target.Resolved- Returns:
- The types of the values on the operand stack.
-
-