@HashCodeAndEqualsPlugin.Enhance public static class ParameterList.ForLoadedExecutable.Dispatcher.ForJava8CapableVm extends java.lang.Object implements ParameterList.ForLoadedExecutable.Dispatcher
java.lang.reflect.Parameter
type.ParameterList.ForLoadedExecutable.Dispatcher.CreationAction, ParameterList.ForLoadedExecutable.Dispatcher.ForJava8CapableVm, ParameterList.ForLoadedExecutable.Dispatcher.ForLegacyVm
Modifier and Type | Field and Description |
---|---|
private java.lang.reflect.Method |
getParameterCount
The
java.lang.reflect.Executable#getParameterCount() method. |
private static java.lang.Object[] |
NO_ARGUMENTS
An empty array that can be used to indicate no arguments to avoid an allocation on a reflective call.
|
Modifier | Constructor and Description |
---|---|
protected |
ForJava8CapableVm(java.lang.reflect.Method getParameterCount)
Creates a new dispatcher for a modern VM.
|
Modifier and Type | Method and Description |
---|---|
ParameterList<ParameterDescription.InDefinedShape> |
describe(java.lang.reflect.Constructor<?> constructor,
ParameterDescription.ForLoadedParameter.ParameterAnnotationSource parameterAnnotationSource)
Describes a
Constructor 's parameters of the given VM. |
ParameterList<ParameterDescription.InDefinedShape> |
describe(java.lang.reflect.Method method,
ParameterDescription.ForLoadedParameter.ParameterAnnotationSource parameterAnnotationSource)
Describes a
Method 's parameters of the given VM. |
int |
getParameterCount(java.lang.Object executable)
Returns the amount of parameters of a given executable..
|
private static final java.lang.Object[] NO_ARGUMENTS
private final java.lang.reflect.Method getParameterCount
java.lang.reflect.Executable#getParameterCount()
method.protected ForJava8CapableVm(java.lang.reflect.Method getParameterCount)
getParameterCount
- The java.lang.reflect.Executable#getParameterCount()
method.public int getParameterCount(java.lang.Object executable)
getParameterCount
in interface ParameterList.ForLoadedExecutable.Dispatcher
executable
- The executable for which the amount of parameters should be found.public ParameterList<ParameterDescription.InDefinedShape> describe(java.lang.reflect.Constructor<?> constructor, ParameterDescription.ForLoadedParameter.ParameterAnnotationSource parameterAnnotationSource)
Constructor
's parameters of the given VM.describe
in interface ParameterList.ForLoadedExecutable.Dispatcher
constructor
- The constructor for which the parameters should be described.parameterAnnotationSource
- The parameter annotation source to query.public ParameterList<ParameterDescription.InDefinedShape> describe(java.lang.reflect.Method method, ParameterDescription.ForLoadedParameter.ParameterAnnotationSource parameterAnnotationSource)
Method
's parameters of the given VM.describe
in interface ParameterList.ForLoadedExecutable.Dispatcher
method
- The method for which the parameters should be described.parameterAnnotationSource
- The parameter annotation source to query.