T
- The annotation type this factory binds.@HashCodeAndEqualsPlugin.Enhance public static class Advice.OffsetMapping.ForField.Resolved.Factory<T extends Annotation> extends Object implements Advice.OffsetMapping.Factory<T>
Advice.OffsetMapping.Factory.AdviceType, Advice.OffsetMapping.Factory.Illegal<T extends Annotation>, Advice.OffsetMapping.Factory.Simple<T extends Annotation>
Constructor and Description |
---|
Factory(Class<T> annotationType,
FieldDescription fieldDescription)
Creates a new factory for binding a specific field with read-only semantics and static typing.
|
Factory(Class<T> annotationType,
FieldDescription fieldDescription,
boolean readOnly,
Assigner.Typing typing)
Creates a new factory for binding a specific field.
|
Modifier and Type | Method and Description |
---|---|
Class<T> |
getAnnotationType()
Returns the annotation type of this factory.
|
Advice.OffsetMapping |
make(ParameterDescription.InDefinedShape target,
AnnotationDescription.Loadable<T> annotation,
Advice.OffsetMapping.Factory.AdviceType adviceType)
Creates a new offset mapping for the supplied parameter if possible.
|
public Factory(Class<T> annotationType, FieldDescription fieldDescription)
annotationType
- The annotation type.fieldDescription
- The field to bind.public Factory(Class<T> annotationType, FieldDescription fieldDescription, boolean readOnly, Assigner.Typing typing)
annotationType
- The annotation type.fieldDescription
- The field to bind.readOnly
- true
if this factory should create a read-only binding.typing
- The typing to use.public Class<T> getAnnotationType()
getAnnotationType
in interface Advice.OffsetMapping.Factory<T extends Annotation>
public Advice.OffsetMapping make(ParameterDescription.InDefinedShape target, AnnotationDescription.Loadable<T> annotation, Advice.OffsetMapping.Factory.AdviceType adviceType)
make
in interface Advice.OffsetMapping.Factory<T extends Annotation>
target
- The parameter description for which to resolve an offset mapping.annotation
- The annotation that triggered this factory.adviceType
- true
if the binding is applied using advice method delegation.null
if no mapping can be resolved for this parameter.Copyright © 2014–2024. All rights reserved.