Package net.bytebuddy.utility.dispatcher
Class JavaDispatcher.Dispatcher.ForDefaultValue.OfNonPrimitiveArray
- java.lang.Object
-
- net.bytebuddy.utility.dispatcher.JavaDispatcher.Dispatcher.ForDefaultValue.OfNonPrimitiveArray
-
- All Implemented Interfaces:
JavaDispatcher.Dispatcher
- Enclosing class:
- JavaDispatcher.Dispatcher.ForDefaultValue
@Enhance protected static class JavaDispatcher.Dispatcher.ForDefaultValue.OfNonPrimitiveArray extends java.lang.Object implements JavaDispatcher.Dispatcher
A dispatcher for a non-primitive array type.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface net.bytebuddy.utility.dispatcher.JavaDispatcher.Dispatcher
JavaDispatcher.Dispatcher.ForConstructor, JavaDispatcher.Dispatcher.ForContainerCreation, JavaDispatcher.Dispatcher.ForDefaultValue, JavaDispatcher.Dispatcher.ForInstanceCheck, JavaDispatcher.Dispatcher.ForNonStaticMethod, JavaDispatcher.Dispatcher.ForStaticMethod, JavaDispatcher.Dispatcher.ForUnresolvedMethod
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.Class<?>
componentType
The represented component type.private java.lang.Object
value
The default value.
-
Constructor Summary
Constructors Modifier Constructor Description protected
OfNonPrimitiveArray(java.lang.Object value, java.lang.Class<?> componentType)
Creates a new dispatcher for the default value of a non-primitive array.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description int
apply(org.objectweb.asm.MethodVisitor methodVisitor, java.lang.reflect.Method method)
Implements this dispatcher in a generated proxy.java.lang.Object
invoke(java.lang.Object[] argument)
Invokes the proxied action.protected static JavaDispatcher.Dispatcher
of(java.lang.Class<?> componentType)
Creates a new dispatcher.
-
-
-
Field Detail
-
value
@ValueHandling(IGNORE) private final java.lang.Object value
The default value.
-
componentType
private final java.lang.Class<?> componentType
The represented component type.
-
-
Method Detail
-
of
protected static JavaDispatcher.Dispatcher of(java.lang.Class<?> componentType)
Creates a new dispatcher.- Parameters:
componentType
- The represented component type.- Returns:
- A dispatcher for the supplied component type.
-
invoke
public java.lang.Object invoke(java.lang.Object[] argument)
Invokes the proxied action.- Specified by:
invoke
in interfaceJavaDispatcher.Dispatcher
- Parameters:
argument
- The arguments provided.- Returns:
- The return value.
-
apply
public int apply(org.objectweb.asm.MethodVisitor methodVisitor, java.lang.reflect.Method method)
Implements this dispatcher in a generated proxy.- Specified by:
apply
in interfaceJavaDispatcher.Dispatcher
- Parameters:
methodVisitor
- The method visitor to implement the method with.method
- The method being implemented.- Returns:
- The maximal size of the operand stack.
-
-