public final class ErrorDetail extends java.lang.Object implements ErrorCodes
Errors with types INVALID_XML, SYNTAX_ERROR or SEMANTIC_ERROR, can be
translated to an instance of this class. All error type constants are defined
in DesignFileException.
| Invalid XML File | Syntax Error | Semantic Error | |
|---|---|---|---|
| type | INVALID_XML | SYNTAX_ERROR | SEMANTIC_ERROR |
| error code | N/A | Y | Y |
| exception name | Y | Y | Y |
| message | Y | Y | Y |
| line number | Y | Y | N/A |
| tag number | Y | Y | N/A |
| element type | N/A | N/A | Y |
| element name | N/A | N/A | Y |
DesignFileExceptionDESIGN_EXCEPTION_UNSUPPORTED_VERSION| 构造器和说明 |
|---|
ErrorDetail(java.lang.Exception e)
Constructs the error detail with a given exception.
|
| 限定符和类型 | 方法和说明 |
|---|---|
static java.util.List<ErrorDetail> |
convertExceptionList(java.util.List<java.lang.Exception> exceptionList)
Converts the exception list to the error detail list.
|
org.eclipse.birt.report.model.core.DesignElement |
getElement()
Returns the element that causes error.
|
java.lang.String |
getErrorCode()
Returns the error code of the cause of the exception.
|
java.lang.String |
getExceptionName()
Returns the name of exception with package prefix.
|
int |
getLineNo()
Returns line number in design file, where error is found.
|
java.lang.String |
getMessage()
Returns the error message.
|
static java.util.List<ErrorDetail> |
getSemanticErrors(java.util.List<ErrorDetail> errors,
java.lang.String errorType)
Returns a list containing the semantic errors with the given error type.
|
java.lang.String |
getSubEditor()
Returns the reference to the editor.
|
java.lang.String |
getTagName()
Returns the tag name that causes error.
|
java.lang.String |
getType()
Returns the error type.
|
java.lang.String |
getValidationID()
Returns the validation ID, which identifies one specific validation.
|
void |
setValidationID(java.lang.String validationID)
Sets the validation ID, which identifies one specific validation.
|
java.lang.String |
toString()
Note output message are locale independent.
|
public ErrorDetail(java.lang.Exception e)
e - the exception types that can be translated are
XMLParserException,
DesignParserException,
SemanticException , SAXException.public java.lang.String toString()
toString 在类中 java.lang.ObjectObject.toString()public org.eclipse.birt.report.model.core.DesignElement getElement()
public java.lang.String getErrorCode()
public java.lang.String getExceptionName()
public int getLineNo()
public java.lang.String getMessage()
public java.lang.String getTagName()
public java.lang.String getType()
DesignFileException.DesignFileExceptionpublic void setValidationID(java.lang.String validationID)
validationID - the validation IDpublic java.lang.String getValidationID()
public static java.util.List<ErrorDetail> convertExceptionList(java.util.List<java.lang.Exception> exceptionList)
exceptionList - list of SemanticException.ErrorDetailpublic static java.util.List<ErrorDetail> getSemanticErrors(java.util.List<ErrorDetail> errors, java.lang.String errorType)
errors - the list of the error detailserrorType - the semantic error type. The possible value is:
DesignFileException.SEMANTIC_ERROR
DesignFileException.SEMANTIC_WARNING
DesignFileException.SYNTAX_ERROR
ErrorDetail.public java.lang.String getSubEditor()
Copyright © 2008 Actuate Corp. All rights reserved.