|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sun.org.apache.xml.internal.resolver.tools.ResolvingParser
ResolvingXMLReader for SAX2.
public class ResolvingParser
A SAX Parser that performs catalog-based entity resolution.
This class implements a SAX Parser that performs entity resolution using the CatalogResolver. The actual, underlying parser is obtained from a SAXParserFactory.
CatalogResolver,
Parser| Field Summary | |
|---|---|
static boolean |
namespaceAware
Deprecated. Make the parser Namespace aware? |
static boolean |
suppressExplanation
Deprecated. Suppress explanatory message? |
static boolean |
validating
Deprecated. Make the parser validating? |
| Constructor Summary | |
|---|---|
ResolvingParser()
Deprecated. Constructor. |
|
ResolvingParser(CatalogManager manager)
Deprecated. Constructor. |
|
| Method Summary | |
|---|---|
void |
characters(char[] ch,
int start,
int length)
Deprecated. SAX DocumentHandler API. |
void |
endDocument()
Deprecated. SAX DocumentHandler API. |
void |
endElement(String name)
Deprecated. SAX DocumentHandler API. |
Catalog |
getCatalog()
Deprecated. Return the Catalog being used. |
void |
ignorableWhitespace(char[] ch,
int start,
int length)
Deprecated. SAX DocumentHandler API. |
void |
notationDecl(String name,
String publicId,
String systemId)
Deprecated. SAX DTDHandler API. |
void |
parse(InputSource input)
Deprecated. SAX Parser API. |
void |
parse(String systemId)
Deprecated. SAX Parser API. |
void |
processingInstruction(String target,
String pidata)
Deprecated. SAX DocumentHandler API. |
InputSource |
resolveEntity(String publicId,
String systemId)
Deprecated. Implements the resolveEntity method
for the SAX interface, using an underlying CatalogResolver
to do the real work. |
void |
setDocumentHandler(DocumentHandler handler)
Deprecated. SAX Parser API. |
void |
setDocumentLocator(Locator locator)
Deprecated. SAX DocumentHandler API. |
void |
setDTDHandler(DTDHandler handler)
Deprecated. SAX Parser API. |
void |
setEntityResolver(EntityResolver resolver)
Deprecated. SAX Parser API. |
void |
setErrorHandler(ErrorHandler handler)
Deprecated. SAX Parser API. |
void |
setLocale(Locale locale)
Deprecated. SAX Parser API. |
void |
startDocument()
Deprecated. SAX DocumentHandler API. |
void |
startElement(String name,
AttributeList atts)
Deprecated. SAX DocumentHandler API. |
void |
unparsedEntityDecl(String name,
String publicId,
String systemId,
String notationName)
Deprecated. SAX DTDHandler API. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static boolean namespaceAware
public static boolean validating
public static boolean suppressExplanation
parse(InputSource)| Constructor Detail |
|---|
public ResolvingParser()
public ResolvingParser(CatalogManager manager)
| Method Detail |
|---|
public Catalog getCatalog()
public void parse(InputSource input)
throws IOException,
SAXException
Note that the JAXP 1.1ea2 parser crashes with an InternalError if it encounters a system identifier that appears to be a relative URI that begins with a slash. For example, the declaration:
<!DOCTYPE book SYSTEM "/path/to/dtd/on/my/system/docbookx.dtd">
would cause such an error. As a convenience, this method catches that error and prints an explanation. (Unfortunately, it's not possible to identify the particular system identifier that causes the problem.)
The underlying error is forwarded after printing the explanatory
message. The message is only every printed once and if
suppressExplanation is set to false before
parsing, it will never be printed.
parse in interface ParserIOException
SAXException
public void parse(String systemId)
throws IOException,
SAXException
parse in interface ParserIOException
SAXExceptionparse(InputSource)public void setDocumentHandler(DocumentHandler handler)
setDocumentHandler in interface Parserpublic void setDTDHandler(DTDHandler handler)
setDTDHandler in interface Parserpublic void setEntityResolver(EntityResolver resolver)
The purpose of this class is to implement an entity resolver. Attempting to set a different one is pointless (and ignored).
setEntityResolver in interface Parserpublic void setErrorHandler(ErrorHandler handler)
setErrorHandler in interface Parser
public void setLocale(Locale locale)
throws SAXException
setLocale in interface ParserSAXException
public void characters(char[] ch,
int start,
int length)
throws SAXException
characters in interface DocumentHandlerSAXException
public void endDocument()
throws SAXException
endDocument in interface DocumentHandlerSAXException
public void endElement(String name)
throws SAXException
endElement in interface DocumentHandlerSAXException
public void ignorableWhitespace(char[] ch,
int start,
int length)
throws SAXException
ignorableWhitespace in interface DocumentHandlerSAXException
public void processingInstruction(String target,
String pidata)
throws SAXException
processingInstruction in interface DocumentHandlerSAXExceptionpublic void setDocumentLocator(Locator locator)
setDocumentLocator in interface DocumentHandler
public void startDocument()
throws SAXException
startDocument in interface DocumentHandlerSAXException
public void startElement(String name,
AttributeList atts)
throws SAXException
startElement in interface DocumentHandlerSAXException
public void notationDecl(String name,
String publicId,
String systemId)
throws SAXException
notationDecl in interface DTDHandlerSAXException
public void unparsedEntityDecl(String name,
String publicId,
String systemId,
String notationName)
throws SAXException
unparsedEntityDecl in interface DTDHandlerSAXException
public InputSource resolveEntity(String publicId,
String systemId)
resolveEntity method
for the SAX interface, using an underlying CatalogResolver
to do the real work.
resolveEntity in interface EntityResolver
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||