Enum Class RNCScannerState

java.lang.Object
java.lang.Enum<RNCScannerState>
org.eclipse.lemminx.extensions.relaxng.grammar.rnc.parser.RNCScannerState
All Implemented Interfaces:
Serializable, Comparable<RNCScannerState>, Constable

public enum RNCScannerState extends Enum<RNCScannerState>
Enumerates the internal states of the RNCScanner state machine.

Currently the scanner uses a single state (WithinContent) because RNC has no multi-line constructs that require state tracking across tokens (unlike XML, which has separate states for tags, attributes, CDATA, etc.). The enum exists for consistency with the XML scanner pattern and to support future extensions (e.g., multi-line string handling or annotation blocks).

  • Enum Constant Details

    • WithinContent

      public static final RNCScannerState WithinContent
      The default scanning state — processing RNC content (declarations, patterns, operators).
  • Method Details

    • values

      public static RNCScannerState[] 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 RNCScannerState 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