Interface IDexAnnotationItem


public interface IDexAnnotationItem
This interface represents annotation items. An annotation item is made of an annotation and visibility information attached to the annotation.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final int
    Visibility constant for build-level annotations.
    static final int
    Visibility constant for runtime-level annotations.
    static final int
    Visibility constant for system-level annotations.
  • Method Summary

    Modifier and Type
    Method
    Description
    Format the annotation visibility into a human-readable string.
    Get the annotation.
    int
    Get the visibility for the annotation.
    default boolean
    Convenience method.
  • Field Details

    • VISIBILITY_BUILD

      static final int VISIBILITY_BUILD
      Visibility constant for build-level annotations.
      See Also:
    • VISIBILITY_RUNTIME

      static final int VISIBILITY_RUNTIME
      Visibility constant for runtime-level annotations.
      See Also:
    • VISIBILITY_SYSTEM

      static final int VISIBILITY_SYSTEM
      Visibility constant for system-level annotations.
      See Also:
  • Method Details

    • getVisibility

      int getVisibility()
      Get the visibility for the annotation.
      Returns:
      the visibility value, refer to the VISIBILITY_* constants
    • formatVisibility

      String formatVisibility()
      Format the annotation visibility into a human-readable string.
      Returns:
    • isSystemLevelAnnotation

      default boolean isSystemLevelAnnotation()
      Convenience method.
      Returns:
      true if the visibility of this annotation is 2
    • getAnnotation

      IDexAnnotation getAnnotation()
      Get the annotation.
      Returns:
      the annotation, or null on error