Top Description Inners Methods
net.bytebuddy.implementation.bind.annotation

public @Interface FieldProxy

extends Annotation
Annotations
@Documented
@Retention:RUNTIME
@Target:PARAMETER
Imports
net.bytebuddy.ByteBuddy, .ClassFileVersion, net.bytebuddy.build.HashCodeAndEqualsPlugin, net.bytebuddy.description.annotation.AnnotationDescription, net.bytebuddy.description.field.FieldDescription, net.bytebuddy.description.method.MethodDescription, .MethodList, .ParameterDescription, net.bytebuddy.description.type.TypeDescription, net.bytebuddy.dynamic.DynamicType, net.bytebuddy.dynamic.scaffold.InstrumentedType, .TypeValidation, net.bytebuddy.dynamic.scaffold.subclass.ConstructorStrategy, net.bytebuddy.implementation.ExceptionMethod, .Implementation, .MethodAccessorFactory, net.bytebuddy.implementation.auxiliary.AuxiliaryType, net.bytebuddy.implementation.bind.MethodDelegationBinder, net.bytebuddy.implementation.bytecode.ByteCodeAppender, .Duplication, .StackManipulation, .TypeCreation, net.bytebuddy.implementation.bytecode.assign.Assigner, net.bytebuddy.implementation.bytecode.member.FieldAccess, .MethodInvocation, .MethodReturn, .MethodVariableAccess, net.bytebuddy.utility.RandomString, net.bytebuddy.jar.asm.MethodVisitor, .Opcodes, java.io.Serializable, java.lang.annotation.*, java.util.Collections

Using this annotation it is possible to access fields by getter and setter types. Before this annotation can be used, it needs to be installed with two types. The getter type must be defined in a single-method interface with a single method that returns an java.lang.Object type and takes no arguments. The setter interface must similarly return void and take a single java.lang.Object argument. After installing these interfaces with the FieldProxy.Binder, this binder needs to be registered with a net.bytebuddy.implementation.MethodDelegation before it can be used.
See Also
net.bytebuddy.implementation.MethodDelegation, net.bytebuddy.implementation.bind.annotation.TargetMethodAnnotationDrivenBinder

Nested and Inner Type Summary

Modifier and TypeClass and Description
public static class
FieldProxy.Binder

A binder for the FieldProxy annotation.

Method Summary

Modifier and TypeMethod and Description
public Class<?>

Returns:

The type that defines the accessed field.
declaringType
()

Determines which type defines the field that is to be accessed.

public boolean

Returns:

true if the proxy should be serializable.
serializableProxy
()

Determines if the proxy should be serializable.

public String

Returns:

The name of the field to be accessed.
value
()

Determines the name of the field that is to be accessed.

Inherited from java.lang.annotation.Annotation:
annotationTypeequalshashCodetoString