Annotation Interface UseField


@Retention(RUNTIME) @Target(FIELD) public @interface UseField
Used to mark fields which should be used by the class generator.

The class generator will reference the annotated field when generating methods, and set it from the constructor arguments

Any field in an abstract class without this field will not be set automatically, even if it matches a property from the implemented event.

  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    boolean
    Indicates whether to use the annotated field directly in the generated 'Annotation.toString()' method, rather than calling the normal accessor method.
  • Element Details

    • overrideToString

      boolean overrideToString
      Indicates whether to use the annotated field directly in the generated 'Annotation.toString()' method, rather than calling the normal accessor method.
      Returns:
      Whether to override the toString
      Default:
      false