Skip navigation links

Oracle® Database XML Java API Reference
12c Release 1 (12.1)

E15981-09


oracle.xml.parser.v2
Class XMLError

java.lang.Object
  extended by oracle.xml.util.XMLError
      extended by oracle.xml.parser.v2.XMLError

All Implemented Interfaces:
DOMError

public class XMLError
extends XMLError
implements DOMError

This class hold error message and the line number where it occured


Field Summary

 

Fields inherited from interface org.w3c.dom.DOMError
SEVERITY_ERROR, SEVERITY_FATAL_ERROR, SEVERITY_WARNING

 

Constructor Summary
XMLError()
          Default constructor

 

Method Summary
 void error(int line, int col, java.lang.String pubId, java.lang.String sysId, java.lang.String mesg, int id, int type, boolean stop)
          Adds a new error to the vector
 boolean error(short severity, java.lang.String mesg, int id, java.lang.String type, DOMException relatedException, java.lang.Object relatedData)
          DOM 3.0 error information
 void flushErrors()
          Flush all the error to the ouput stream output stream defaults or to error handler
 void flushErrors1()
           
 void flushNodes(java.lang.String errMsg, java.lang.String val)
          Set the properties for the nodes where validation error occured.
 boolean getDOMErrorOption()
          Gets the flag for DOM Errors to be returned.
 ErrorHandler getErrorHandler()
          Return register error handler
 java.util.Vector getListTrees()
          This method returns the list of stacks that was built with the nodes where the schema validation failed
 boolean getStopNormalizing()
           
 void setDOMErrorOption(boolean docerrflag)
          Sets the flag for DOM Errors to be returned.
 void setErrorHandler(ErrorHandler err)
          Register error handler

 

Methods inherited from class oracle.xml.util.XMLError
error, error, error0, error1, error2, error3, flushErrorStream, formatErrorMesg, getColumnNumber, getException, getFirstError, getLineNumber, getLocator, getMessage, getMessage, getMessage0, getMessage1, getMessage2, getMessage3, getMessage4, getMessage5, getMessageId, getMessageType, getNumExceptions, getNumFatalMessages, getNumMessages, getPublicId, getSystemId, printErrorListener, reset, setErrorStream, setErrorStream, setErrorStream, setException, setLocale, setLocator, showWarnings

 

Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Methods inherited from interface org.w3c.dom.DOMError
getLocation, getMessage, getRelatedData, getRelatedException, getSeverity, getType

 

Constructor Detail

XMLError

public XMLError()
Default constructor

Method Detail

setErrorHandler

public void setErrorHandler(ErrorHandler err)
Register error handler
Parameters:
err - - ErrorHandler

getErrorHandler

public ErrorHandler getErrorHandler()
Return register error handler
Returns:
ErrorHandler

error

public void error(int line,
                  int col,
                  java.lang.String pubId,
                  java.lang.String sysId,
                  java.lang.String mesg,
                  int id,
                  int type,
                  boolean stop)
           throws XMLParseException
Adds a new error to the vector
Parameters:
line - the line number where error occurs
col - the column number where the error occurs
pubId - the public Identifier
sysId - the system identifier
mesg - the error message
id - the error id
type - the error type
stop - boolean to indicate if the processing needs to be stopped.
Throws:
XMLParseException - in case of a fatal error

flushErrors

public void flushErrors()
                 throws XMLParseException
Flush all the error to the ouput stream output stream defaults or to error handler
Throws:
XMLParseException - in case of a fatal error

flushErrors1

public void flushErrors1()
                  throws XMLParseException,
                         SAXParseException,
                         SAXException,
                         java.io.IOException
Throws:
XMLParseException
SAXParseException
SAXException
java.io.IOException

flushNodes

public void flushNodes(java.lang.String errMsg,
                       java.lang.String val)
Set the properties for the nodes where validation error occured. Flush the XMLNode objects from the locator and add them to a a stack.Finally, the stack is added to a Vector which keeps track all the nodes where Validation failed.
Parameters:
errMsg - - Error message returned from validator
val - - Node/Attribute name.

getListTrees

public java.util.Vector getListTrees()
This method returns the list of stacks that was built with the nodes where the schema validation failed

setDOMErrorOption

public void setDOMErrorOption(boolean docerrflag)
Sets the flag for DOM Errors to be returned. This flag should be used only when trying to validate an already parsed document
Parameters:
docerrflag - - boolean

getDOMErrorOption

public boolean getDOMErrorOption()
Gets the flag for DOM Errors to be returned. This flag should be used only when trying to validate a parsed XML document
Returns:
docerrflag - boolean

error

public boolean error(short severity,
                     java.lang.String mesg,
                     int id,
                     java.lang.String type,
                     DOMException relatedException,
                     java.lang.Object relatedData)
DOM 3.0 error information

getStopNormalizing

public boolean getStopNormalizing()

Skip navigation links

Oracle® Database XML Java API Reference
12c Release 1 (12.1)

E15981-09


Copyright © 2003, 2014, Oracle and/or its affiliates. All rights reserved.