Skip to content

Enum Class ErrorCode

Javadoc 27 generates this reference during each site build from the exported packages and the annotation processor. The Java guide shows the API in use.

java.lang.Object
java.lang.Enum<ErrorCode>
dev.gecode.iris.ErrorCode
All Implemented Interfaces:
Serializable, Comparable<ErrorCode>, Constable
public enum ErrorCode extends Enum<ErrorCode>
A stable identifier for a kind of error, from the Specification's error registry.

Compare codes rather than messages: the wording of a message can change.

  • Enum Constant Details

    • SPEC_UTF8

      public static final ErrorCode SPEC_UTF8
      Reader spec is not valid UTF-8.
    • SPEC_STRING

      public static final ErrorCode SPEC_STRING
      Invalid reader-spec string.
    • SPEC_NUMBER

      public static final ErrorCode SPEC_NUMBER
      Invalid or unrepresentable reader-spec numeric literal.
    • SPEC_CHARACTER

      public static final ErrorCode SPEC_CHARACTER
      Unrecognized reader-spec character.
    • SPEC_PATTERN

      public static final ErrorCode SPEC_PATTERN
      Malformed pattern or capture, or an invalid capture type.
    • SPEC_SYNTAX

      public static final ErrorCode SPEC_SYNTAX
      Required syntactic item absent or unrecognized statement.
    • SPEC_PLACEMENT

      public static final ErrorCode SPEC_PLACEMENT
      Statement or setting used in a prohibited position.
    • SPEC_NAME

      public static final ErrorCode SPEC_NAME
      Reserved or discard name used where a real definition or binding is required.
    • SPEC_NAME_CONFLICT

      public static final ErrorCode SPEC_NAME_CONFLICT
      Conflicting type, value, record, or comprehension names.
    • SPEC_UNKNOWN_TYPE

      public static final ErrorCode SPEC_UNKNOWN_TYPE
      Reading type name is not known at this point.
    • SPEC_TYPE

      public static final ErrorCode SPEC_TYPE
      Reading type incompatible with a declaration, list or option.
    • SPEC_NESTING

      public static final ErrorCode SPEC_NESTING
      Block or expression nesting limit of the reader spec exceeded.
    • SPEC_FUNCTION

      public static final ErrorCode SPEC_FUNCTION
      Unknown function, or an invalid call form or arity.
    • SPEC_CONSTANT

      public static final ErrorCode SPEC_CONSTANT
      Unknown Gecode host constant.
    • SPEC_RECORD_SCOPE

      public static final ErrorCode SPEC_RECORD_SCOPE
      Reference to a record, list or field outside its permitted repeat scope.
    • SPEC_FIELD

      public static final ErrorCode SPEC_FIELD
      Invalid field selection or ambiguous field definition.
    • SPEC_RECORD_VALUE

      public static final ErrorCode SPEC_RECORD_VALUE
      Record or list used as a value, an indexed record or a comprehension list where prohibited.
    • SPEC_CHECK_SCOPE

      public static final ErrorCode SPEC_CHECK_SCOPE
      Check attempts to range over incompatible or ambiguous repeat definitions.
    • BUDGET

      public static final ErrorCode BUDGET
      A work budget is exhausted.
    • CHECK_FAILED

      public static final ErrorCode CHECK_FAILED
      A check condition is false.
    • CHECK_RECORDS

      public static final ErrorCode CHECK_RECORDS
      Runtime record collections cannot be aligned for a check.
    • COMPARISON_TYPE

      public static final ErrorCode COMPARISON_TYPE
      Comparison operands violate scalar or numeric requirements.
    • COUNT

      public static final ErrorCode COUNT
      A size, count or base expression is not a permitted count.
    • DIVISION_ZERO

      public static final ErrorCode DIVISION_ZERO
      Integer division or remainder by zero.
    • EXPECTED_TOKEN

      public static final ErrorCode EXPECTED_TOKEN
      Required literal token absent or different.
    • EXPECTED_VALUE

      public static final ErrorCode EXPECTED_VALUE
      Input does not satisfy the reading type or domain, or the line of values is absent.
    • EXPONENT

      public static final ErrorCode EXPONENT
      Integer exponent is negative.
    • FIELD_UNDEFINED

      public static final ErrorCode FIELD_UNDEFINED
      A field is unavailable in the selected runtime record.
    • FIND_MATCH

      public static final ErrorCode FIND_MATCH
      No remaining line matches a find pattern.
    • FUNCTION_EMPTY

      public static final ErrorCode FUNCTION_EMPTY
      A min or max receives no integer leaves.
    • FUNCTION_TYPE

      public static final ErrorCode FUNCTION_TYPE
      Function or comprehension operand has the wrong type or shape.
    • INDEX_CONTEXT

      public static final ErrorCode INDEX_CONTEXT
      An index statement executes outside a repeat.
    • INDEX_MISMATCH

      public static final ErrorCode INDEX_MISMATCH
      Input row index differs from the expected repeat index.
    • INDEX_RANGE

      public static final ErrorCode INDEX_RANGE
      Array or record-list index is outside its bounds.
    • INDEX_SCALAR

      public static final ErrorCode INDEX_SCALAR
      Attempt to index a scalar.
    • INDEX_TYPE

      public static final ErrorCode INDEX_TYPE
      Index expression is not an integer scalar.
    • INSTANCE_EMPTY

      public static final ErrorCode INSTANCE_EMPTY
      Reading requires an instance but none exists.
    • INSTANCE_NOT_FOUND

      public static final ErrorCode INSTANCE_NOT_FOUND
      Requested instance number or name does not exist.
    • INSTANCE_NUMBER

      public static final ErrorCode INSTANCE_NUMBER
      Numeric instance selection is below one.
    • INSTANCE_SELECTION

      public static final ErrorCode INSTANCE_SELECTION
      Multiple instances require an explicit selection.
    • INTEGER_OVERFLOW

      public static final ErrorCode INTEGER_OVERFLOW
      Checked integer arithmetic or value adjustment overflows.
    • INTEGER_TYPE

      public static final ErrorCode INTEGER_TYPE
      Integer arithmetic requires integer scalar operands.
    • LAYOUT

      public static final ErrorCode LAYOUT
      Layout value, name, or matrix shape is invalid.
    • LINE_MATCH

      public static final ErrorCode LINE_MATCH
      No match for a line pattern, either for line or a required sections arm.
    • LIST_TERMINATOR

      public static final ErrorCode LIST_TERMINATOR
      List terminator has an invalid type or shape.
    • NAME_UNDEFINED

      public static final ErrorCode NAME_UNDEFINED
      Referenced value or record collection is not defined yet.
    • NO_PROGRESS

      public static final ErrorCode NO_PROGRESS
      An instance or indefinite repeat body consumes no input.
    • OFFSET_TYPE

      public static final ErrorCode OFFSET_TYPE
      Offset expression is not an integer scalar.
    • PARAM_MISSING

      public static final ErrorCode PARAM_MISSING
      Required parameter was not supplied.
    • PARAM_TYPE

      public static final ErrorCode PARAM_TYPE
      Supplied parameter cannot convert to its default's numeric value type.
    • PARAM_UNKNOWN

      public static final ErrorCode PARAM_UNKNOWN
      Caller supplied a parameter not declared by the reader spec.
    • PATTERN_REFERENCE

      public static final ErrorCode PATTERN_REFERENCE
      Current-value pattern reference is neither a string nor an integer scalar.
    • RANGE_BOUNDS

      public static final ErrorCode RANGE_BOUNDS
      Range bound is not an integer scalar.
    • REPEAT_DEPTH

      public static final ErrorCode REPEAT_DEPTH
      Repeated values have inconsistent depths.
    • REPEAT_MISSING

      public static final ErrorCode REPEAT_MISSING
      Required scalar is absent from some or all nonempty repeat iterations.
    • REPEAT_TERMINATOR

      public static final ErrorCode REPEAT_TERMINATOR
      Required terminating token is absent before input ends.
    • SECTIONS_REPEATED

      public static final ErrorCode SECTIONS_REPEATED
      A sections arm matches a second line.
    • SECTIONS_UNEXPECTED

      public static final ErrorCode SECTIONS_UNEXPECTED
      No sections arm matches the current line and skip other is absent.
    • SIZE_LIMIT

      public static final ErrorCode SIZE_LIMIT
      Array or matrix cell count exceeds the supported structural bound.
    • SKIP_EOF

      public static final ErrorCode SKIP_EOF
      A requested line cannot be skipped at end of input.
    • SYMBOL

      public static final ErrorCode SYMBOL
      Alphabet reading encounters end of input or an unrecognized symbol.
    • TRAILING_INPUT

      public static final ErrorCode TRAILING_INPUT
      Disallowed input remains after execution finishes.
    • TYPE_UNDEFINED

      public static final ErrorCode TYPE_UNDEFINED
      A parsed named type has not been evaluated on the executed path.
    • VALUE_TYPE_MIX

      public static final ErrorCode VALUE_TYPE_MIX
      Repeated or list values mix strings and numbers.
    • UTF8

      public static final ErrorCode UTF8
      The supplied input or a word or rest value that was read contains invalid UTF-8.
  • Method Details

    • values

      public static ErrorCode[] 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 ErrorCode 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
    • code

      public String code()
      Returns the text of this code, such as E-SPEC-SYNTAX.
      Returns:
      the text of this code, such as E-SPEC-SYNTAX