Class TypeDescription.Generic.OfParameterizedType.ForReifiedType
java.lang.Object
net.bytebuddy.description.ModifierReviewable.AbstractBase
net.bytebuddy.description.type.TypeDescription.Generic.AbstractBase
net.bytebuddy.description.type.TypeDescription.Generic.OfParameterizedType
net.bytebuddy.description.type.TypeDescription.Generic.OfParameterizedType.ForReifiedType
- All Implemented Interfaces:
Iterable<TypeDefinition>, AnnotationSource, ModifierReviewable, ModifierReviewable.ForFieldDescription, ModifierReviewable.ForMethodDescription, ModifierReviewable.ForModuleDescription, ModifierReviewable.ForModuleRequirement, ModifierReviewable.ForParameterDescription, ModifierReviewable.ForTypeDefinition, ModifierReviewable.OfAbstraction, ModifierReviewable.OfByteCodeElement, ModifierReviewable.OfEnumeration, ModifierReviewable.OfMandatable, NamedElement, TypeDefinition, TypeDescription.Generic
- Enclosing class:
TypeDescription.Generic.OfParameterizedType
public static class TypeDescription.Generic.OfParameterizedType.ForReifiedType
extends TypeDescription.Generic.OfParameterizedType
A representation of a parameterized type that is a super type of a raw type but preserves the minimal type information
that is required for allowing creating correct erasures for overridden methods. All members' types are erased and all
type arguments are reduced to their erasure.
-
Nested Class Summary
Nested classes/interfaces inherited from class TypeDescription.Generic.OfParameterizedType
TypeDescription.Generic.OfParameterizedType.ForGenerifiedErasure, TypeDescription.Generic.OfParameterizedType.ForLoadedType, TypeDescription.Generic.OfParameterizedType.ForReifiedType, TypeDescription.Generic.OfParameterizedType.Latent, TypeDescription.Generic.OfParameterizedType.RenderingDelegateNested classes/interfaces inherited from interface AnnotationSource
AnnotationSource.Empty, AnnotationSource.ExplicitNested classes/interfaces inherited from interface ModifierReviewable
ModifierReviewable.AbstractBase, ModifierReviewable.ForFieldDescription, ModifierReviewable.ForMethodDescription, ModifierReviewable.ForModuleDescription, ModifierReviewable.ForModuleRequirement, ModifierReviewable.ForParameterDescription, ModifierReviewable.ForTypeDefinition, ModifierReviewable.OfAbstraction, ModifierReviewable.OfByteCodeElement, ModifierReviewable.OfEnumeration, ModifierReviewable.OfMandatableNested classes/interfaces inherited from interface NamedElement
NamedElement.WithDescriptor, NamedElement.WithGenericName, NamedElement.WithOptionalName, NamedElement.WithRuntimeNameNested classes/interfaces inherited from interface TypeDefinition
TypeDefinition.Sort, TypeDefinition.SuperClassIteratorNested classes/interfaces inherited from interface TypeDescription.Generic
TypeDescription.Generic.AbstractBase, TypeDescription.Generic.AnnotationReader, TypeDescription.Generic.Builder, TypeDescription.Generic.LazyProjection, TypeDescription.Generic.LazyProxy, TypeDescription.Generic.OfGenericArray, TypeDescription.Generic.OfNonGenericType, TypeDescription.Generic.OfParameterizedType, TypeDescription.Generic.OfTypeVariable, TypeDescription.Generic.OfWildcardType, TypeDescription.Generic.Visitor<T> -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final TypeDescription.GenericThe represented parameterized type.Fields inherited from interface ModifierReviewable
EMPTY_MASKFields inherited from interface NamedElement
EMPTY_NAME, NO_NAMEFields inherited from interface TypeDefinition
RAW_TYPES_PROPERTYFields inherited from interface TypeDescription.Generic
ANNOTATION, CLASS, OBJECT, UNDEFINED, VOID -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedForReifiedType(TypeDescription.Generic parameterizedType) Creates a new reified parameterized type. -
Method Summary
Modifier and TypeMethodDescriptionReturns the erasure of this type.Returns a list of annotations that are declared by this instance.Returns the fields that this type declares.Returns the methods that this type declares.Returns the interfaces that this type implements.Returns the owner type of this type.Returns the super class of this type.Returns the type arguments of this type.Methods inherited from class TypeDescription.Generic.OfParameterizedType
accept, equals, findBindingOf, getActualName, getComponentType, getLowerBounds, getRecordComponents, getSort, getStackSize, getSymbol, getTypeName, getTypeVariableSource, getUpperBounds, hashCode, isArray, isPrimitive, isRecord, iterator, represents, toStringMethods inherited from class TypeDescription.Generic.AbstractBase
asGenericType, asRawType, getModifiersMethods inherited from class ModifierReviewable.AbstractBase
getEnumerationState, getFieldManifestation, getFieldPersistence, getMandate, getMethodManifestation, getMethodStrictness, getOpenness, getOwnership, getParameterManifestation, getProvisioningState, getRequiredPhase, getSynchronizationState, getSyntheticState, getTransitivity, getTypeManifestation, getVisibility, isAbstract, isAnnotation, isBridge, isDeprecated, isEnum, isFinal, isInterface, isMandated, isNative, isOpen, isPackagePrivate, isPrivate, isProtected, isPublic, isStatic, isStaticPhase, isStrict, isSynchronized, isSynthetic, isTransient, isTransitive, isVarArgs, isVolatileMethods inherited from interface Iterable
forEach, spliteratorMethods inherited from interface ModifierReviewable
getSyntheticState, isFinal, isSyntheticMethods inherited from interface ModifierReviewable.ForTypeDefinition
getTypeManifestation, isAnnotation, isInterfaceMethods inherited from interface ModifierReviewable.OfAbstraction
isAbstractMethods inherited from interface ModifierReviewable.OfByteCodeElement
getOwnership, getVisibility, isDeprecated, isPackagePrivate, isPrivate, isProtected, isPublic, isStaticMethods inherited from interface ModifierReviewable.OfEnumeration
getEnumerationState, isEnum
-
Field Details
-
parameterizedType
The represented parameterized type.
-
-
Constructor Details
-
ForReifiedType
Creates a new reified parameterized type.- Parameters:
parameterizedType- The represented parameterized type.
-
-
Method Details
-
getSuperClass
Returns the super class of this type. A super type is only defined for non-generic types (TypeDefinition.Sort.NON_GENERIC), parameterized types (TypeDefinition.Sort.PARAMETERIZED) or generic array types (TypeDefinition.Sort.GENERIC_ARRAY) types. Interface types and theObjectclass do not define a super class wherenullis returned. Array types defineObjectas their direct super class.- Specified by:
getSuperClassin interfaceTypeDefinition- Overrides:
getSuperClassin classTypeDescription.Generic.OfParameterizedType- Returns:
- The super class of this type or
nullif no super class exists for this type.
-
getInterfaces
Returns the interfaces that this type implements. A super type is only defined for non-generic types (TypeDefinition.Sort.NON_GENERIC), parameterized types (TypeDefinition.Sort.PARAMETERIZED) or generic array types (TypeDefinition.Sort.GENERIC_ARRAY) types.- Specified by:
getInterfacesin interfaceTypeDefinition- Overrides:
getInterfacesin classTypeDescription.Generic.OfParameterizedType- Returns:
- The interfaces that this type implements.
-
getDeclaredFields
Returns the fields that this type declares. A super type is only defined for non-generic types (TypeDefinition.Sort.NON_GENERIC), parameterized types (TypeDefinition.Sort.PARAMETERIZED) or generic array types (TypeDefinition.Sort.GENERIC_ARRAY) types. Generic array types never define fields and the returned list is always empty for such types.- Specified by:
getDeclaredFieldsin interfaceTypeDefinition- Specified by:
getDeclaredFieldsin interfaceTypeDescription.Generic- Overrides:
getDeclaredFieldsin classTypeDescription.Generic.OfParameterizedType- Returns:
- The fields that this type declares. A super type is only defined for non-generic types (
TypeDefinition.Sort.NON_GENERIC), parameterized types (TypeDefinition.Sort.PARAMETERIZED) or generic array types (TypeDefinition.Sort.GENERIC_ARRAY) types. Generic array types never define methods and the returned list is always empty for such types.
-
getDeclaredMethods
Returns the methods that this type declares.- Specified by:
getDeclaredMethodsin interfaceTypeDefinition- Specified by:
getDeclaredMethodsin interfaceTypeDescription.Generic- Overrides:
getDeclaredMethodsin classTypeDescription.Generic.OfParameterizedType- Returns:
- The methods that this type declares.
-
getTypeArguments
Returns the type arguments of this type.
Parameters are only well-defined for parameterized types (
TypeDefinition.Sort.PARAMETERIZED). For all other types, this method throws anIllegalStateException.- Returns:
- A list of this type's type parameters.
-
getOwnerType
Returns the owner type of this type. A type's owner type describes a nested type's declaring type. If it exists, the returned type can be a non-generic or parameterized type. If a class has no declaring type,
nullis returned.An owner type is only well-defined for parameterized types (
TypeDefinition.Sort.PARAMETERIZED), for non-generic types (TypeDefinition.Sort.NON_GENERIC) and for generic arrays (TypeDefinition.Sort.GENERIC_ARRAY). For all other types, this method throws anIllegalStateException.- Returns:
- This type's owner type or
nullif no owner type exists.
-
asErasure
Returns the erasure of this type. Wildcard types (TypeDefinition.Sort.WILDCARD) do not have a well-defined erasure and cause anIllegalStateExceptionto be thrown.- Returns:
- The erasure of this type.
-
getDeclaredAnnotations
Returns a list of annotations that are declared by this instance.- Returns:
- A list of declared annotations.
-