Enum ErrorEvent.ErrorType

java.lang.Object
java.lang.Enum<ErrorEvent.ErrorType>
org.ec4j.core.parser.ErrorEvent.ErrorType
All Implemented Interfaces:
Serializable, Comparable<ErrorEvent.ErrorType>, java.lang.constant.Constable
Enclosing class:
ErrorEvent

public static enum ErrorEvent.ErrorType extends Enum<ErrorEvent.ErrorType>
A way to keep apart various kinds of errors in a type safe way.
  • Enum Constant Details

  • Field Details

    • syntaxError

      private final boolean syntaxError
  • Constructor Details

    • ErrorType

      private ErrorType(boolean syntaxError)
  • Method Details

    • values

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

      public static ErrorEvent.ErrorType valueOf(String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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 type has no constant with the specified name
      NullPointerException - if the argument is null
    • isSyntaxError

      public boolean isSyntaxError()
      Syntax errors are such ones that have to do with the .editorconfig file structure, such a as property without value, or property name not followed by equal sign. Non-syntax errors that may happen with the current implementation are only of two kinds: (i) broken Glob pattern or (ii) invalid value for the given registered PropertyType.
      Returns:
      true is this is a syntax error; false otherwise