Package net.bytebuddy.description.field
Class FieldDescription.Latent
java.lang.Object
net.bytebuddy.description.ModifierReviewable.AbstractBase
net.bytebuddy.description.field.FieldDescription.AbstractBase
net.bytebuddy.description.field.FieldDescription.InDefinedShape.AbstractBase
net.bytebuddy.description.field.FieldDescription.Latent
- All Implemented Interfaces:
AnnotationSource
,ByteCodeElement
,ByteCodeElement.Member
,ByteCodeElement.TypeDependant<FieldDescription.InDefinedShape,
,FieldDescription.Token> DeclaredByType
,DeclaredByType.WithMandatoryDeclaration
,FieldDescription
,FieldDescription.InDefinedShape
,ModifierReviewable
,ModifierReviewable.ForFieldDescription
,ModifierReviewable.ForMethodDescription
,ModifierReviewable.ForParameterDescription
,ModifierReviewable.ForTypeDefinition
,ModifierReviewable.OfAbstraction
,ModifierReviewable.OfByteCodeElement
,ModifierReviewable.OfEnumeration
,NamedElement
,NamedElement.WithDescriptor
,NamedElement.WithGenericName
,NamedElement.WithRuntimeName
- Enclosing interface:
FieldDescription
A latent field description describes a field that is not attached to a declaring
TypeDescription
.-
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.ByteCodeElement
ByteCodeElement.Member, ByteCodeElement.TypeDependant<T extends ByteCodeElement.TypeDependant<?,
S>, S extends ByteCodeElement.Token<S>> Nested classes/interfaces inherited from interface net.bytebuddy.description.DeclaredByType
DeclaredByType.WithMandatoryDeclaration
Nested classes/interfaces inherited from interface net.bytebuddy.description.field.FieldDescription
FieldDescription.AbstractBase, FieldDescription.ForLoadedField, FieldDescription.InDefinedShape, FieldDescription.InGenericShape, FieldDescription.Latent, FieldDescription.SignatureToken, FieldDescription.Token, FieldDescription.TypeSubstituting
Nested classes/interfaces inherited from interface net.bytebuddy.description.field.FieldDescription.InDefinedShape
FieldDescription.InDefinedShape.AbstractBase
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
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final List
<? extends AnnotationDescription> The annotations of this field.private final TypeDescription
The type for which this field is defined.private final TypeDescription.Generic
The type of the field.private final int
The field's modifiers.private final String
The name of the field.Fields inherited from interface net.bytebuddy.description.field.FieldDescription
NO_DEFAULT_VALUE
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.NamedElement.WithDescriptor
NON_GENERIC_SIGNATURE
-
Constructor Summary
ConstructorsConstructorDescriptionLatent
(TypeDescription declaringType, String name, int modifiers, TypeDescription.Generic fieldType, List<? extends AnnotationDescription> declaredAnnotations) Creates a new latent field description.Latent
(TypeDescription declaringType, FieldDescription.Token token) Creates a new latent field description. -
Method Summary
Modifier and TypeMethodDescriptionReturns a list of annotations that are declared by this instance.Returns the declaring type of this instance.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 the described field.Methods inherited from class net.bytebuddy.description.field.FieldDescription.InDefinedShape.AbstractBase
asDefined
Methods inherited from class net.bytebuddy.description.field.FieldDescription.AbstractBase
asSignatureToken, asToken, equals, getActualModifiers, getActualName, getDescriptor, getGenericSignature, getInternalName, hashCode, isAccessibleTo, isVisibleTo, toGenericString, 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.ByteCodeElement
isAccessibleTo, isVisibleTo
Methods inherited from interface net.bytebuddy.description.ByteCodeElement.TypeDependant
asToken
Methods inherited from interface net.bytebuddy.description.field.FieldDescription
asSignatureToken, getActualModifiers
Methods inherited from interface net.bytebuddy.description.ModifierReviewable
getSyntheticState, isFinal, isSynthetic
Methods inherited from interface net.bytebuddy.description.ModifierReviewable.ForFieldDescription
getFieldManifestation, getFieldPersistence, isTransient, isVolatile
Methods inherited from interface net.bytebuddy.description.ModifierReviewable.OfByteCodeElement
getOwnership, getVisibility, isDeprecated, isPackagePrivate, isPrivate, isProtected, isPublic, isStatic
Methods inherited from interface net.bytebuddy.description.ModifierReviewable.OfEnumeration
getEnumerationState, isEnum
Methods inherited from interface net.bytebuddy.description.NamedElement
getActualName
Methods inherited from interface net.bytebuddy.description.NamedElement.WithDescriptor
getDescriptor, getGenericSignature
Methods inherited from interface net.bytebuddy.description.NamedElement.WithGenericName
toGenericString
Methods inherited from interface net.bytebuddy.description.NamedElement.WithRuntimeName
getInternalName
-
Field Details
-
declaringType
The type for which this field is defined. -
name
The name of the field. -
modifiers
private final int modifiersThe field's modifiers. -
fieldType
The type of the field. -
declaredAnnotations
The annotations of this field.
-
-
Constructor Details
-
Latent
Creates a new latent field description. All provided types are attached to this instance before they are returned.- Parameters:
declaringType
- The declaring type of the field.token
- A token representing the field's shape.
-
Latent
public Latent(TypeDescription declaringType, String name, int modifiers, TypeDescription.Generic fieldType, List<? extends AnnotationDescription> declaredAnnotations) Creates a new latent field description. All provided types are attached to this instance before they are returned.- Parameters:
declaringType
- The declaring type of the field.name
- The name of the field.modifiers
- The type of the field.fieldType
- The field's modifiers.declaredAnnotations
- The annotations of this field.
-
-
Method Details
-
getType
Returns the type of the described field.- Returns:
- The type of the described field.
-
getDeclaredAnnotations
Returns a list of annotations that are declared by this instance.- Returns:
- A list of declared annotations.
-
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.- Returns:
- The binary ame of this byte code element as visible from within a running Java application.
-
getDeclaringType
Returns the declaring type of this instance.- Returns:
- The declaring type or
null
if no such type exists.
-
getModifiers
public int getModifiers()Returns the modifier that is described by this object.- Returns:
- The modifier that is described by this object.
-