Class CstEnumRef

All Implemented Interfaces:
TypeBearer, ToHuman, Comparable<Constant>

public final class CstEnumRef extends CstMemberRef
Constant type to represent a reference to a particular constant value of an enumerated type.
  • Constructor Details

    • CstEnumRef

      public CstEnumRef(CstNat nat)
      Constructs an instance.
      Parameters:
      nat - non-null; the name-and-type; the defining class is derived from this
  • Method Details

    • typeName

      public String typeName()
      Returns the human name for the particular type of constant this instance is.
      Specified by:
      typeName in class Constant
      Returns:
      non-null; the name
    • getType

      public Type getType()
      Gets the type associated with this instance. Note: This returns the enumerated type.
      Returns:
      non-null; the type
    • getFieldRef

      public CstFieldRef getFieldRef()
      Get a CstFieldRef that corresponds with this instance.
      Returns:
      non-null; the corresponding field reference