Package net.bytebuddy.dynamic
Class Transformer.ForMethod.TransformedMethod.TransformedParameter
java.lang.Object
net.bytebuddy.description.ModifierReviewable.AbstractBase
net.bytebuddy.description.method.ParameterDescription.AbstractBase
net.bytebuddy.dynamic.Transformer.ForMethod.TransformedMethod.TransformedParameter
- All Implemented Interfaces:
AnnotationSource
,ByteCodeElement.TypeDependant<ParameterDescription.InDefinedShape,
,ParameterDescription.Token> ParameterDescription
,ModifierReviewable
,ModifierReviewable.ForFieldDescription
,ModifierReviewable.ForMethodDescription
,ModifierReviewable.ForParameterDescription
,ModifierReviewable.ForTypeDefinition
,ModifierReviewable.OfAbstraction
,ModifierReviewable.OfByteCodeElement
,ModifierReviewable.OfEnumeration
,NamedElement
,NamedElement.WithOptionalName
,NamedElement.WithRuntimeName
- Enclosing class:
Transformer.ForMethod.TransformedMethod
protected class Transformer.ForMethod.TransformedMethod.TransformedParameter
extends ParameterDescription.AbstractBase
A transformed method's parameter.
-
Nested Class Summary
Nested classes/interfaces inherited from interface net.bytebuddy.description.annotation.AnnotationSource
AnnotationSource.Empty, AnnotationSource.Explicit
Nested classes/interfaces inherited from interface net.bytebuddy.description.ModifierReviewable
ModifierReviewable.AbstractBase, ModifierReviewable.ForFieldDescription, ModifierReviewable.ForMethodDescription, ModifierReviewable.ForParameterDescription, ModifierReviewable.ForTypeDefinition, ModifierReviewable.OfAbstraction, ModifierReviewable.OfByteCodeElement, ModifierReviewable.OfEnumeration
Nested classes/interfaces inherited from interface net.bytebuddy.description.NamedElement
NamedElement.WithDescriptor, NamedElement.WithGenericName, NamedElement.WithOptionalName, NamedElement.WithRuntimeName
Nested classes/interfaces inherited from interface net.bytebuddy.description.method.ParameterDescription
ParameterDescription.AbstractBase, ParameterDescription.ForLoadedParameter<T extends AccessibleObject>, ParameterDescription.InDefinedShape, ParameterDescription.InGenericShape, ParameterDescription.Latent, ParameterDescription.Token, ParameterDescription.TypeSubstituting
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final int
The index of the transformed method.private final ParameterDescription.Token
The token representing the transformed method parameter's properties.Fields inherited from interface net.bytebuddy.description.ModifierReviewable
EMPTY_MASK
Fields inherited from interface net.bytebuddy.description.NamedElement
EMPTY_NAME, NO_NAME
Fields inherited from interface net.bytebuddy.description.method.ParameterDescription
NAME_PREFIX
-
Constructor Summary
ConstructorsModifierConstructorDescriptionprotected
TransformedParameter
(int index, ParameterDescription.Token parameterToken) Creates a transformed parameter. -
Method Summary
Modifier and TypeMethodDescriptionReturns this type dependant in its defined shape, i.e.Returns a list of annotations that are declared by this instance.Returns the method that declares this parameter.int
getIndex()
Returns this parameter's index.int
Returns the modifier that is described by this object.getName()
Returns the binary name of this byte code element.getType()
Returns the type of this parameter.boolean
Checks if this parameter has an explicit modifier.boolean
isNamed()
Returnstrue
if this element has an explicit name.Methods inherited from class net.bytebuddy.description.method.ParameterDescription.AbstractBase
asToken, equals, getActualName, getInternalName, getOffset, hashCode, toString
Methods inherited from class net.bytebuddy.description.ModifierReviewable.AbstractBase
getEnumerationState, getFieldManifestation, getFieldPersistence, getMethodManifestation, getMethodStrictness, getOwnership, getParameterManifestation, getProvisioningState, getSynchronizationState, getSyntheticState, getTypeManifestation, getVisibility, isAbstract, isAnnotation, isBridge, isDeprecated, isEnum, isFinal, isInterface, isMandated, isNative, isPackagePrivate, isPrivate, isProtected, isPublic, isStatic, isStrict, isSynchronized, isSynthetic, isTransient, isVarArgs, isVolatile
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface net.bytebuddy.description.ModifierReviewable
getSyntheticState, isFinal, isSynthetic
Methods inherited from interface net.bytebuddy.description.ModifierReviewable.ForParameterDescription
getParameterManifestation, getProvisioningState, isMandated
-
Field Details
-
index
private final int indexThe index of the transformed method. -
parameterToken
The token representing the transformed method parameter's properties.
-
-
Constructor Details
-
TransformedParameter
Creates a transformed parameter.- Parameters:
index
- The index of the transformed method.parameterToken
- The token representing the transformed method parameter's properties.
-
-
Method Details
-
getType
Returns the type of this parameter.- Returns:
- The type of this parameter.
-
getDeclaringMethod
Returns the method that declares this parameter.- Returns:
- The method that declares this parameter.
-
getIndex
public int getIndex()Returns this parameter's index.- Returns:
- The index of this parameter.
-
isNamed
public boolean isNamed()Returnstrue
if this element has an explicit name.- Returns:
true
if this element has an explicit name.
-
hasModifiers
public boolean hasModifiers()Checks if this parameter has an explicit modifier. A parameter without a modifier is simply treated as if it had a modifier of zero.- Returns:
true
if this parameter defines explicit modifiers.
-
getName
Returns the binary name of this byte code element. If no well-defined internal name is known for this element, the actual name is returned.- Specified by:
getName
in interfaceNamedElement.WithRuntimeName
- Overrides:
getName
in classParameterDescription.AbstractBase
- Returns:
- The binary ame of this byte code element as visible from within a running Java application.
-
getModifiers
public int getModifiers()Returns the modifier that is described by this object.- Specified by:
getModifiers
in interfaceModifierReviewable
- Overrides:
getModifiers
in classParameterDescription.AbstractBase
- Returns:
- The modifier that is described by this object.
-
getDeclaredAnnotations
Returns a list of annotations that are declared by this instance.- Returns:
- A list of declared annotations.
-
asDefined
Returns this type dependant in its defined shape, i.e. the form it is declared in and without its type variable's resolved.- Returns:
- This type dependant in its defined shape.
-