Annotation Interface Mixin


@Target(TYPE) @Retention(SOURCE) public @interface Mixin
Annotation used to define a mixin in the compile-time processing context. A mixin allows adding new annotations to an existing class.

This annotation is marked as experimental and is subject to change or removal in future versions.

Since:
4.9
Author:
Denis Stepanov
  • Element Details

    • value

      Class<?> value
      Returns:
      The target of the mixin
    • target

      String target
      A way to specify the target class if it's not accessible. In that case the value should be Object.class.
      Returns:
      The target of the mixin
      Default:
      ""
    • includeAnnotations

      @AliasFor(annotation=Filter.class, member="includeAnnotations") String[] includeAnnotations
      Filters which annotations are included. The predicate will use String.startsWith(String) to verify if the annotation name should be included.
      Returns:
      The full annotation name or a package to check if the annotation should be included.
      Default:
      {}
    • excludeAnnotations

      @AliasFor(annotation=Filter.class, member="excludeAnnotations") String[] excludeAnnotations
      Opposite of includeAnnotations(). Filters which annotations to exclude.
      Returns:
      The full annotation name or a package to check if the annotation should not be excluded.
      Default:
      {}
    • removeAnnotations

      @AliasFor(annotation=Filter.class, member="removeAnnotations") String[] removeAnnotations
      Remove the annotation from the target element. The predicate will use String.startsWith(String) to verify if the annotation name should be removed.
      Returns:
      The full annotation name or a package to check if the annotation should not be removed.
      Default:
      {}