Enum Class ScopeInfo

java.lang.Object
java.lang.Enum<ScopeInfo>
net.sourceforge.pmd.lang.java.symbols.table.ScopeInfo
All Implemented Interfaces:
Serializable, Comparable<ScopeInfo>, Constable

public enum ScopeInfo extends Enum<ScopeInfo>
A scope tag for java shadow chains. This gives information about why a declaration is in scope.
  • Enum Constant Details

    • ENCLOSING_TYPE

      public static final ScopeInfo ENCLOSING_TYPE
      An enclosing class.
    • ENCLOSING_TYPE_MEMBER

      public static final ScopeInfo ENCLOSING_TYPE_MEMBER
      Member of an enclosing class, that is not inherited.
    • INHERITED

      public static final ScopeInfo INHERITED
      Inherited by some enclosing class.
    • METHOD_MEMBER

      public static final ScopeInfo METHOD_MEMBER
    • TYPE_PARAM

      public static final ScopeInfo TYPE_PARAM
      A type parameter of some enclosing class.
    • LOCAL

      public static final ScopeInfo LOCAL
      Local var, including lambda parameters and catch parameters.
    • MODULE_IMPORT

      public static final ScopeInfo MODULE_IMPORT
    • IMPORT_ON_DEMAND

      public static final ScopeInfo IMPORT_ON_DEMAND
    • SAME_PACKAGE

      public static final ScopeInfo SAME_PACKAGE
    • JAVA_LANG

      public static final ScopeInfo JAVA_LANG
    • SINGLE_IMPORT

      public static final ScopeInfo SINGLE_IMPORT
    • SIMPLE_COMPILATION_UNIT

      public static final ScopeInfo SIMPLE_COMPILATION_UNIT
    • SAME_FILE

      public static final ScopeInfo SAME_FILE
      Sibling types in the same file, that are not nested into one another.
    • FORMAL_PARAM

      public static final ScopeInfo FORMAL_PARAM
      Method or constructor formal parameter (lambdas are treated as locals).
  • Method Details

    • values

      public static ScopeInfo[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static ScopeInfo valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null