Interface AccessFlags

All Superinterfaces:
ClassElement, ClassFileElement, FieldElement, MethodElement

public sealed interface AccessFlags extends ClassElement, MethodElement, FieldElement
Models the access flags for a class, method, or field. Delivered as a ClassElement, FieldElement, or MethodElement when traversing the corresponding model type.
Since:
24
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the access flags.
    int
    Returns the access flags, as a bit mask.
    boolean
    Returns whether the specified flag is present.
    Returns the classfile location for this element, which is either class, method, or field.
  • Method Details

    • flagsMask

      int flagsMask()
      Returns the access flags, as a bit mask.
      Returns:
      the access flags, as a bit mask
    • flags

      Set<AccessFlag> flags()
      Returns the access flags.
      Returns:
      the access flags
    • has

      boolean has(AccessFlag flag)
      Returns whether the specified flag is present. The specified flag should be a valid flag for the classfile location associated with this element otherwise false is returned.
      Parameters:
      flag - the flag to test
      Returns:
      whether the specified flag is present
    • location

      Returns the classfile location for this element, which is either class, method, or field.
      Returns:
      the classfile location for this element, which is either class, method, or field