Package org.apache.uima.cas.impl
Class XCASParsingException
java.lang.Object
java.lang.Throwable
java.lang.Exception
org.xml.sax.SAXException
org.xml.sax.SAXParseException
org.apache.uima.cas.impl.XCASParsingException
- All Implemented Interfaces:
Serializable
Exception class for package org.apache.uima.cas.impl. Automatically generated from message
catalog.
- See Also:
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
Error parsing XCAS from source {0} at line {1}, column {2}: array element <i> may not have attributes.static final int
Error parsing XCAS from source {0} at line {1}, column {2}: expected array element <i> but found: <{3}>.static final int
Error parsing XMI-CAS from source {0} at line {1}, column {2}: A byte array value must have an even number of hex characters.static final int
Error parsing XCAS from source {0} at line {1}, column {2}: number of array elements exceeds specified array size.static final int
Error parsing XCAS from source {0} at line {1}, column {2}: expected numeric value, but found: {3}.static final int
Error parsing XCAS from source {0} at line {1}, column {2}: unknown attribute for array type: {3}.static final int
Error parsing XCAS from source {0} at line {1}, column {2}: size of array must be >= 0, but is: {3}.static final int
Error parsing XCAS from source {0} at line {1}, column {2}: value of _id attribute must be integer, but is: {3}.static final int
Error parsing XCAS from source {0} at line {1}, column {2}: expected integer value, but found: {3}.static final int
Error parsing XCAS or XMI-CAS from source {0} at line {1}, column {2}: in subtype of AnnotationBase, sofa reference is missing.static final int
Error parsing XCAS from source {0} at line {1}, column {2}: expected text but found element: <{3}>.static final int
Error parsing XCAS from source {0} at line {1}, column {2}: unknown feature: {3}.static final int
Error parsing XMI-CAS from source {0} at line {1}, column {2}: xmi id {3} is referenced but not defined.static final int
Error parsing XCAS from source {0} at line {1}, column {2}: unknown type: {3}.static final int
Error parsing XCAS from source {0} at line {1}, column {2}: expected <CAS> root tag but found: <{3}>. -
Constructor Summary
-
Method Summary
Methods inherited from class org.xml.sax.SAXParseException
getColumnNumber, getLineNumber, getPublicId, getSystemId
Methods inherited from class org.xml.sax.SAXException
getCause, getException
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getLocalizedMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
-
Field Details
-
WRONG_ROOT_TAG
public static final int WRONG_ROOT_TAGError parsing XCAS from source {0} at line {1}, column {2}: expected <CAS> root tag but found: <{3}>.- See Also:
-
TEXT_EXPECTED
public static final int TEXT_EXPECTEDError parsing XCAS from source {0} at line {1}, column {2}: expected text but found element: <{3}>.- See Also:
-
ARRAY_ELE_EXPECTED
public static final int ARRAY_ELE_EXPECTEDError parsing XCAS from source {0} at line {1}, column {2}: expected array element <i> but found: <{3}>.- See Also:
-
ARRAY_ELE_ATTRS
public static final int ARRAY_ELE_ATTRSError parsing XCAS from source {0} at line {1}, column {2}: array element <i> may not have attributes.- See Also:
-
UNKNOWN_TYPE
public static final int UNKNOWN_TYPEError parsing XCAS from source {0} at line {1}, column {2}: unknown type: {3}.- See Also:
-
ILLEGAL_ID
public static final int ILLEGAL_IDError parsing XCAS from source {0} at line {1}, column {2}: value of _id attribute must be integer, but is: {3}.- See Also:
-
ILLEGAL_ARRAY_SIZE
public static final int ILLEGAL_ARRAY_SIZEError parsing XCAS from source {0} at line {1}, column {2}: size of array must be >= 0, but is: {3}.- See Also:
-
ILLEGAL_ARRAY_ATTR
public static final int ILLEGAL_ARRAY_ATTRError parsing XCAS from source {0} at line {1}, column {2}: unknown attribute for array type: {3}.- See Also:
-
UNKNOWN_FEATURE
public static final int UNKNOWN_FEATUREError parsing XCAS from source {0} at line {1}, column {2}: unknown feature: {3}.- See Also:
-
INTEGER_EXPECTED
public static final int INTEGER_EXPECTEDError parsing XCAS from source {0} at line {1}, column {2}: expected integer value, but found: {3}.- See Also:
-
FLOAT_EXPECTED
public static final int FLOAT_EXPECTEDError parsing XCAS from source {0} at line {1}, column {2}: expected numeric value, but found: {3}.- See Also:
-
EXCESS_ARRAY_ELE
public static final int EXCESS_ARRAY_ELEError parsing XCAS from source {0} at line {1}, column {2}: number of array elements exceeds specified array size.- See Also:
-
UNKNOWN_ID
public static final int UNKNOWN_IDError parsing XMI-CAS from source {0} at line {1}, column {2}: xmi id {3} is referenced but not defined.- See Also:
-
SOFA_REF_MISSING
public static final int SOFA_REF_MISSINGError parsing XCAS or XMI-CAS from source {0} at line {1}, column {2}: in subtype of AnnotationBase, sofa reference is missing.- See Also:
-
BYTE_ARRAY_LENGTH_NOT_EVEN
public static final int BYTE_ARRAY_LENGTH_NOT_EVENError parsing XMI-CAS from source {0} at line {1}, column {2}: A byte array value must have an even number of hex characters.- See Also:
-
-
Constructor Details
-
XCASParsingException
public XCASParsingException(int error) Create a newXCASParsingException
- Parameters:
error
- The error code.
-
-
Method Details
-
getError
public int getError()- Returns:
- The error code for the exception. This may be useful when the error needs to be handed over language boundaries. Instead of handing over the complete exception object, return the error code, and the receiving application can look up the error in the message file. Unfortunately, the error parameters get lost that way.
-
getMessage
- Overrides:
getMessage
in classSAXException
- Returns:
- The message of the exception. Useful for including the text in another exception.
-
toString
- Overrides:
toString
in classSAXParseException
- Returns:
- The same as getMessage(), but prefixed with
"XCASParsingException: "
.
-
addArgument
Add an argument to aXCASParsingException
object. Excess arguments will be ignored, and missing arguments will have the valuenull
. Add arguments in the order in which they are specified in the message catalog (i.e. add %1 first, %2 next, and so on). Adding anull String
has no effect! So if you don't know the value of an argument, use something like""
or"UNKNOWN"
, but notnull
.- Parameters:
s
- the argument to add- Returns:
- true if the argument was added, false if the argument was already added or was out of range
-