public abstract static class Advice.Dispatcher.OffsetMapping.ForField extends Object implements Advice.Dispatcher.OffsetMapping
Modifier and Type | Class and Description |
---|---|
protected static class |
Advice.Dispatcher.OffsetMapping.ForField.Factory
A factory for a
Advice.Dispatcher.OffsetMapping.Target.ForField offset mapping. |
protected static class |
Advice.Dispatcher.OffsetMapping.ForField.WithExplicitType
An offset mapping for a field with an explicit declaring type.
|
protected static class |
Advice.Dispatcher.OffsetMapping.ForField.WithImplicitType
An offset mapping for a field with an implicit declaring type.
|
Advice.Dispatcher.OffsetMapping.Context, Advice.Dispatcher.OffsetMapping.ForBoxedArguments, Advice.Dispatcher.OffsetMapping.ForBoxedReturnValue, Advice.Dispatcher.OffsetMapping.ForEnterValue, Advice.Dispatcher.OffsetMapping.ForField, Advice.Dispatcher.OffsetMapping.ForInstrumentedType, Advice.Dispatcher.OffsetMapping.ForOrigin, Advice.Dispatcher.OffsetMapping.ForParameter, Advice.Dispatcher.OffsetMapping.ForReturnValue, Advice.Dispatcher.OffsetMapping.ForStubValue, Advice.Dispatcher.OffsetMapping.ForThisReference, Advice.Dispatcher.OffsetMapping.ForThrowable, Advice.Dispatcher.OffsetMapping.ForUnusedValue, Advice.Dispatcher.OffsetMapping.ForUserValue<T extends Annotation>, Advice.Dispatcher.OffsetMapping.Illegal, Advice.Dispatcher.OffsetMapping.Target
Modifier and Type | Field and Description |
---|---|
protected String |
name
The name of the field.
|
protected boolean |
readOnly
true if this mapping is read-only. |
protected TypeDescription |
targetType
The expected type that the field can be assigned to.
|
Modifier | Constructor and Description |
---|---|
protected |
ForField(String name,
TypeDescription targetType,
boolean readOnly)
Creates an offset mapping for a field.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(Object object) |
protected abstract FieldLocator |
fieldLocator(TypeDescription instrumentedType)
Returns a field locator for this instance.
|
int |
hashCode() |
Advice.Dispatcher.OffsetMapping.Target |
resolve(MethodDescription.InDefinedShape instrumentedMethod,
Advice.Dispatcher.OffsetMapping.Context context)
Resolves an offset mapping to a given target offset.
|
protected final String name
protected final TypeDescription targetType
protected final boolean readOnly
true
if this mapping is read-only.protected ForField(String name, TypeDescription targetType, boolean readOnly)
name
- The name of the field.targetType
- The expected type that the field can be assigned to.readOnly
- true
if this mapping is read-only.public Advice.Dispatcher.OffsetMapping.Target resolve(MethodDescription.InDefinedShape instrumentedMethod, Advice.Dispatcher.OffsetMapping.Context context)
Advice.Dispatcher.OffsetMapping
resolve
in interface Advice.Dispatcher.OffsetMapping
instrumentedMethod
- The instrumented method for which the mapping is to be resolved.context
- The context in which the offset mapping is applied.protected abstract FieldLocator fieldLocator(TypeDescription instrumentedType)
instrumentedType
- The instrumented type.Copyright © 2014–2016. All rights reserved.