public class MethodWrapper
extends java.lang.Object
Method for easy access| Constructor and Description |
|---|
MethodWrapper(MethodStream parent,
java.lang.reflect.Method method) |
| Modifier and Type | Method and Description |
|---|---|
<T> T |
invoke()
Invoke the
Method without any args |
<T> T |
invokeArgs(java.lang.Object... args)
Invoke the
Method with the given arguments |
<T> T |
invokeInstance(java.lang.Object instance,
java.lang.Object... args)
Invoke the
Method with the give arguments and instance |
ModifierWrapper |
modifier()
Get the
ModifierWrapper of the Method |
java.lang.String |
name()
Get the name of the
Method |
java.lang.Class<?> |
owner()
Get the owner
Class of the Method |
java.lang.Class<?>[] |
parameterTypes()
Get the parameter types of the
Method |
MethodStream |
parent()
Get the parent
MethodStream |
java.lang.reflect.Method |
raw()
Get the raw
Method |
java.lang.Class<?> |
returnType()
Get the return type of the
Method |
public MethodWrapper(MethodStream parent, java.lang.reflect.Method method)
public MethodStream parent()
MethodStreampublic java.lang.reflect.Method raw()
Methodpublic java.lang.String name()
Methodpublic java.lang.Class<?> returnType()
Methodpublic java.lang.Class<?>[] parameterTypes()
Methodpublic java.lang.Class<?> owner()
Class of the Methodpublic ModifierWrapper modifier()
ModifierWrapper of the Methodpublic <T> T invoke()
Method without any argspublic <T> T invokeArgs(java.lang.Object... args)
Method with the given argumentsargs - The arguments to pass to the Methodpublic <T> T invokeInstance(java.lang.Object instance,
java.lang.Object... args)
Method with the give arguments and instanceinstance - The instance of the ownerargs - The arguments to pass to the Method