protected static class MethodConstant.ForConstructor extends MethodConstant implements MethodConstant.CanCache
MethodConstant
for loading
a Constructor
instance onto the operand stack.MethodConstant.CachedConstructor, MethodConstant.CachedMethod, MethodConstant.CanCache, MethodConstant.CanCacheIllegal, MethodConstant.ForConstructor, MethodConstant.ForMethod, MethodConstant.PrivilegedLookup
StackManipulation.Compound, StackManipulation.Illegal, StackManipulation.Size, StackManipulation.Trivial
Modifier and Type | Field and Description |
---|---|
private static MethodDescription.InDefinedShape |
GET_CONSTRUCTOR
The
Class.getConstructor(Class[]) method. |
private static MethodDescription.InDefinedShape |
GET_DECLARED_CONSTRUCTOR
The
Class.getDeclaredConstructor(Class[]) method. |
methodDescription
Modifier | Constructor and Description |
---|---|
protected |
ForConstructor(MethodDescription.InDefinedShape methodDescription)
Creates a new
MethodConstant for
creating a Constructor instance. |
Modifier and Type | Method and Description |
---|---|
protected MethodDescription.InDefinedShape |
accessorMethod()
Returns the method for loading a declared method or constructor onto the operand stack.
|
StackManipulation |
cached()
Returns this method constant as a cached version.
|
protected StackManipulation |
methodName()
Returns a stack manipulation that loads the method name onto the operand stack if this is required.
|
apply, equals, hashCode, isValid, of, ofPrivileged, privileged, typeConstantsFor
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
apply, isValid
private static final MethodDescription.InDefinedShape GET_CONSTRUCTOR
Class.getConstructor(Class[])
method.private static final MethodDescription.InDefinedShape GET_DECLARED_CONSTRUCTOR
Class.getDeclaredConstructor(Class[])
method.protected ForConstructor(MethodDescription.InDefinedShape methodDescription)
MethodConstant
for
creating a Constructor
instance.methodDescription
- The constructor to be loaded onto the stack.protected StackManipulation methodName()
MethodConstant
methodName
in class MethodConstant
protected MethodDescription.InDefinedShape accessorMethod()
MethodConstant
accessorMethod
in class MethodConstant
public StackManipulation cached()
cached
in interface MethodConstant.CanCache