public static class ParameterDescription.Token extends java.lang.Object implements ByteCodeElement.Token<ParameterDescription.Token>
Modifier and Type | Class and Description |
---|---|
static class |
ParameterDescription.Token.TypeList
A list of types represented as a list of parameter tokens.
|
ByteCodeElement.Token.TokenList<S extends ByteCodeElement.Token<S>>
Modifier and Type | Field and Description |
---|---|
private java.util.List<? extends AnnotationDescription> |
annotations
A list of parameter annotations.
|
private java.lang.Integer |
modifiers
The modifiers of the parameter or
null if no explicit modifiers is defined. |
private java.lang.String |
name
The name of the parameter or
null if no explicit name is defined. |
static java.lang.Integer |
NO_MODIFIERS
Indicator for a method parameter without explicit modifiers.
|
static java.lang.String |
NO_NAME
Indicator for a method parameter without an explicit name.
|
private TypeDescription.Generic |
type
The type of the represented parameter.
|
Constructor and Description |
---|
Token(TypeDescription.Generic type)
Creates a new parameter token without an explicit name, an explicit modifier or annotations.
|
Token(TypeDescription.Generic type,
java.util.List<? extends AnnotationDescription> annotations)
Creates a new parameter token without an explicit name or an explicit modifier.
|
Token(TypeDescription.Generic type,
java.util.List<? extends AnnotationDescription> annotations,
java.lang.String name,
java.lang.Integer modifiers)
Creates a new parameter token.
|
Token(TypeDescription.Generic type,
java.lang.String name,
java.lang.Integer modifiers)
Creates a parameter token without annotations.
|
Modifier and Type | Method and Description |
---|---|
ParameterDescription.Token |
accept(TypeDescription.Generic.Visitor<? extends TypeDescription.Generic> visitor)
Transforms the types represented by this token by applying the given visitor to them.
|
boolean |
equals(java.lang.Object other) |
AnnotationList |
getAnnotations()
Returns the annotations of the represented method parameter.
|
java.lang.Integer |
getModifiers()
Returns the modifiers of the represented method parameter.
|
java.lang.String |
getName()
Returns the name of the represented method parameter.
|
TypeDescription.Generic |
getType()
Returns the type of the represented method parameter.
|
int |
hashCode() |
java.lang.String |
toString() |
public static final java.lang.String NO_NAME
public static final java.lang.Integer NO_MODIFIERS
private final TypeDescription.Generic type
private final java.util.List<? extends AnnotationDescription> annotations
private final java.lang.String name
null
if no explicit name is defined.private final java.lang.Integer modifiers
null
if no explicit modifiers is defined.public Token(TypeDescription.Generic type)
type
- The type of the represented parameter.public Token(TypeDescription.Generic type, java.util.List<? extends AnnotationDescription> annotations)
type
- The type of the represented parameter.annotations
- The annotations of the parameter.public Token(TypeDescription.Generic type, java.lang.String name, java.lang.Integer modifiers)
type
- The type of the represented parameter.name
- The name of the parameter or null
if no explicit name is defined.modifiers
- The modifiers of the parameter or null
if no explicit modifiers is defined.public Token(TypeDescription.Generic type, java.util.List<? extends AnnotationDescription> annotations, java.lang.String name, java.lang.Integer modifiers)
type
- The type of the represented parameter.annotations
- The annotations of the parameter.name
- The name of the parameter or null
if no explicit name is defined.modifiers
- The modifiers of the parameter or null
if no explicit modifiers is defined.public TypeDescription.Generic getType()
public AnnotationList getAnnotations()
public java.lang.String getName()
null
if no explicit name is defined.public java.lang.Integer getModifiers()
null
if no explicit modifiers is defined.public ParameterDescription.Token accept(TypeDescription.Generic.Visitor<? extends TypeDescription.Generic> visitor)
accept
in interface ByteCodeElement.Token<ParameterDescription.Token>
visitor
- The visitor to transform all types that are represented by this token.public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object other)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object