Class OASISXMLCatalogReader
- java.lang.Object
-
- com.sun.org.apache.xml.internal.resolver.readers.SAXCatalogReader
-
- com.sun.org.apache.xml.internal.resolver.readers.OASISXMLCatalogReader
-
- All Implemented Interfaces:
CatalogReader,SAXCatalogParser,ContentHandler,DocumentHandler
- Direct Known Subclasses:
ExtendedXMLCatalogReader
public class OASISXMLCatalogReader extends SAXCatalogReader implements SAXCatalogParser
Parse OASIS Entity Resolution Technical Committee XML Catalog files.- Version:
- 1.0
- Author:
- Norman Walsh Norman.Walsh@Sun.COM
- See Also:
Catalog
-
-
Field Summary
Fields Modifier and Type Field Description protected StackbaseURIStackprotected CatalogcatalogThe catalog object needs to be stored by the object so that SAX callbacks can use it.static StringnamespaceNameThe namespace name of OASIS ERTC catalogsprotected StacknamespaceStackprotected StackoverrideStackstatic Stringtr9401NamespaceNameThe namespace name of OASIS ERTC TR9401 catalog extension-
Fields inherited from class com.sun.org.apache.xml.internal.resolver.readers.SAXCatalogReader
debug, namespaceMap, parserClass, parserFactory
-
-
Constructor Summary
Constructors Constructor Description OASISXMLCatalogReader()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcharacters(char[] ch, int start, int length)The SAXcharactersmethod does nothing.booleancheckAttributes(Attributes atts, String attName)booleancheckAttributes(Attributes atts, String attName1, String attName2)voidendDocument()The SAXendDocumentmethod does nothing.voidendElement(String namespaceURI, String localName, String qName)The SAXendElementmethod does nothing.voidendPrefixMapping(String prefix)The SAXendPrefixMappingmethod does nothing.CataloggetCatalog()Get the current catalog.voidignorableWhitespace(char[] ch, int start, int length)The SAXignorableWhitespacemethod does nothing.protected booleaninExtensionNamespace()Are we in an extension namespace?voidprocessingInstruction(String target, String data)The SAXprocessingInstructionmethod does nothing.voidsetCatalog(Catalog catalog)Set the current catalog.voidsetDocumentLocator(Locator locator)The SAXsetDocumentLocatormethod does nothing.voidskippedEntity(String name)The SAXskippedEntitymethod does nothing.voidstartDocument()The SAXstartDocumentmethod does nothing.voidstartElement(String namespaceURI, String localName, String qName, Attributes atts)The SAXstartElementmethod recognizes elements from the plain catalog format and instantiates CatalogEntry objects for them.voidstartPrefixMapping(String prefix, String uri)The SAXstartPrefixMappingmethod does nothing.-
Methods inherited from class com.sun.org.apache.xml.internal.resolver.readers.SAXCatalogReader
endElement, getCatalogParser, getParserClass, getParserFactory, readCatalog, readCatalog, setCatalogParser, setParserClass, setParserFactory, startElement
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.xml.sax.DocumentHandler
endElement, startElement
-
-
-
-
Field Detail
-
catalog
protected Catalog catalog
The catalog object needs to be stored by the object so that SAX callbacks can use it.
-
namespaceName
public static final String namespaceName
The namespace name of OASIS ERTC catalogs- See Also:
- Constant Field Values
-
tr9401NamespaceName
public static final String tr9401NamespaceName
The namespace name of OASIS ERTC TR9401 catalog extension- See Also:
- Constant Field Values
-
baseURIStack
protected Stack baseURIStack
-
overrideStack
protected Stack overrideStack
-
namespaceStack
protected Stack namespaceStack
-
-
Method Detail
-
setCatalog
public void setCatalog(Catalog catalog)
Set the current catalog.- Specified by:
setCatalogin interfaceSAXCatalogParser
-
getCatalog
public Catalog getCatalog()
Get the current catalog.
-
inExtensionNamespace
protected boolean inExtensionNamespace()
Are we in an extension namespace?- Returns:
- true if the current stack of open namespaces includes an extension namespace.
-
setDocumentLocator
public void setDocumentLocator(Locator locator)
The SAXsetDocumentLocatormethod does nothing.- Specified by:
setDocumentLocatorin interfaceContentHandler- Specified by:
setDocumentLocatorin interfaceDocumentHandler- Overrides:
setDocumentLocatorin classSAXCatalogReader
-
startDocument
public void startDocument() throws SAXExceptionThe SAXstartDocumentmethod does nothing.- Specified by:
startDocumentin interfaceContentHandler- Specified by:
startDocumentin interfaceDocumentHandler- Overrides:
startDocumentin classSAXCatalogReader- Throws:
SAXException
-
endDocument
public void endDocument() throws SAXExceptionThe SAXendDocumentmethod does nothing.- Specified by:
endDocumentin interfaceContentHandler- Specified by:
endDocumentin interfaceDocumentHandler- Overrides:
endDocumentin classSAXCatalogReader- Throws:
SAXException
-
startElement
public void startElement(String namespaceURI, String localName, String qName, Attributes atts) throws SAXException
The SAXstartElementmethod recognizes elements from the plain catalog format and instantiates CatalogEntry objects for them.- Specified by:
startElementin interfaceContentHandler- Overrides:
startElementin classSAXCatalogReader- Parameters:
namespaceURI- The namespace name of the element.localName- The local name of the element.qName- The QName of the element.atts- The list of attributes on the element.- Throws:
SAXException- See Also:
CatalogEntry
-
checkAttributes
public boolean checkAttributes(Attributes atts, String attName)
-
checkAttributes
public boolean checkAttributes(Attributes atts, String attName1, String attName2)
-
endElement
public void endElement(String namespaceURI, String localName, String qName) throws SAXException
The SAXendElementmethod does nothing.- Specified by:
endElementin interfaceContentHandler- Overrides:
endElementin classSAXCatalogReader- Throws:
SAXException
-
characters
public void characters(char[] ch, int start, int length) throws SAXExceptionThe SAXcharactersmethod does nothing.- Specified by:
charactersin interfaceContentHandler- Specified by:
charactersin interfaceDocumentHandler- Overrides:
charactersin classSAXCatalogReader- Throws:
SAXException
-
ignorableWhitespace
public void ignorableWhitespace(char[] ch, int start, int length) throws SAXExceptionThe SAXignorableWhitespacemethod does nothing.- Specified by:
ignorableWhitespacein interfaceContentHandler- Specified by:
ignorableWhitespacein interfaceDocumentHandler- Overrides:
ignorableWhitespacein classSAXCatalogReader- Throws:
SAXException
-
processingInstruction
public void processingInstruction(String target, String data) throws SAXException
The SAXprocessingInstructionmethod does nothing.- Specified by:
processingInstructionin interfaceContentHandler- Specified by:
processingInstructionin interfaceDocumentHandler- Overrides:
processingInstructionin classSAXCatalogReader- Throws:
SAXException
-
skippedEntity
public void skippedEntity(String name) throws SAXException
The SAXskippedEntitymethod does nothing.- Specified by:
skippedEntityin interfaceContentHandler- Overrides:
skippedEntityin classSAXCatalogReader- Throws:
SAXException
-
startPrefixMapping
public void startPrefixMapping(String prefix, String uri) throws SAXException
The SAXstartPrefixMappingmethod does nothing.- Specified by:
startPrefixMappingin interfaceContentHandler- Overrides:
startPrefixMappingin classSAXCatalogReader- Throws:
SAXException
-
endPrefixMapping
public void endPrefixMapping(String prefix) throws SAXException
The SAXendPrefixMappingmethod does nothing.- Specified by:
endPrefixMappingin interfaceContentHandler- Overrides:
endPrefixMappingin classSAXCatalogReader- Throws:
SAXException
-
-