Class Default.Binder.TypeLocator.ForType
- java.lang.Object
-
- net.bytebuddy.implementation.bind.annotation.Default.Binder.TypeLocator.ForType
-
- All Implemented Interfaces:
Default.Binder.TypeLocator
- Enclosing interface:
- Default.Binder.TypeLocator
@Enhance public static class Default.Binder.TypeLocator.ForType extends java.lang.Object implements Default.Binder.TypeLocator
A type locator that returns a given type.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface net.bytebuddy.implementation.bind.annotation.Default.Binder.TypeLocator
Default.Binder.TypeLocator.ForParameterType, Default.Binder.TypeLocator.ForType
-
-
Field Summary
Fields Modifier and Type Field Description private TypeDescriptiontypeDescriptionThe type to be returned upon resolution.
-
Constructor Summary
Constructors Modifier Constructor Description protectedForType(TypeDescription typeDescription)Creates a new type locator for a given type.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected static Default.Binder.TypeLocatorof(TypeDescription typeDescription)Resolves a type locator based upon an annotation value.TypeDescriptionresolve(TypeDescription.Generic parameterType)Resolves the target type.
-
-
-
Field Detail
-
typeDescription
private final TypeDescription typeDescription
The type to be returned upon resolution.
-
-
Constructor Detail
-
ForType
protected ForType(TypeDescription typeDescription)
Creates a new type locator for a given type.- Parameters:
typeDescription- The type to be returned upon resolution.
-
-
Method Detail
-
of
protected static Default.Binder.TypeLocator of(TypeDescription typeDescription)
Resolves a type locator based upon an annotation value.- Parameters:
typeDescription- The annotation's value.- Returns:
- The appropriate type locator.
-
resolve
public TypeDescription resolve(TypeDescription.Generic parameterType)
Resolves the target type.- Specified by:
resolvein interfaceDefault.Binder.TypeLocator- Parameters:
parameterType- The type of the target parameter.- Returns:
- The proxy type.
-
-