Package org.apache.xerces.impl.dtd
Class XMLDTDDescription
java.lang.Object
org.apache.xerces.util.XMLResourceIdentifierImpl
org.apache.xerces.impl.dtd.XMLDTDDescription
- All Implemented Interfaces:
org.apache.xerces.xni.grammars.XMLDTDDescription,org.apache.xerces.xni.grammars.XMLGrammarDescription,org.apache.xerces.xni.XMLResourceIdentifier
public class XMLDTDDescription
extends XMLResourceIdentifierImpl
implements org.apache.xerces.xni.grammars.XMLDTDDescription
All information specific to DTD grammars.
INTERNAL:
- Usage of this class is not supported. It may be altered or removed at any time.
- Version:
- $Id: XMLDTDDescription.java 699892 2008-09-28 21:08:27Z mrglavas $
- Author:
- Neil Graham, IBM
-
Field Summary
FieldsFields inherited from class org.apache.xerces.util.XMLResourceIdentifierImpl
fBaseSystemId, fExpandedSystemId, fLiteralSystemId, fNamespace, fPublicIdFields inherited from interface org.apache.xerces.xni.grammars.XMLGrammarDescription
XML_DTD, XML_SCHEMA -
Constructor Summary
ConstructorsConstructorDescriptionXMLDTDDescription(String publicId, String literalId, String baseId, String expandedId, String rootName) XMLDTDDescription(org.apache.xerces.xni.parser.XMLInputSource source) XMLDTDDescription(org.apache.xerces.xni.XMLResourceIdentifier id, String rootName) -
Method Summary
Modifier and TypeMethodDescriptionbooleanCompares this grammar with the given grammar.Return the type of this grammar.Return the root name of this DTD.inthashCode()Returns the hash code of this grammar Because our .equals method is so complex, we just return a very simple hash that might avoid calls to the equals method a bit...voidsetPossibleRoots(ArrayList possibleRoots) Set possible rootsvoidsetPossibleRoots(Vector possibleRoots) Set possible rootsvoidsetRootName(String rootName) Set the root nameMethods inherited from class org.apache.xerces.util.XMLResourceIdentifierImpl
clear, getBaseSystemId, getExpandedSystemId, getLiteralSystemId, getNamespace, getPublicId, setBaseSystemId, setExpandedSystemId, setLiteralSystemId, setNamespace, setPublicId, setValues, setValues, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.xerces.xni.XMLResourceIdentifier
getBaseSystemId, getExpandedSystemId, getLiteralSystemId, getNamespace, getPublicId, setBaseSystemId, setExpandedSystemId, setLiteralSystemId, setNamespace, setPublicId
-
Field Details
-
fRootName
-
fPossibleRoots
-
-
Constructor Details
-
XMLDTDDescription
-
XMLDTDDescription
-
XMLDTDDescription
public XMLDTDDescription(org.apache.xerces.xni.parser.XMLInputSource source)
-
-
Method Details
-
getGrammarType
Description copied from interface:org.apache.xerces.xni.grammars.XMLGrammarDescriptionReturn the type of this grammar.- Specified by:
getGrammarTypein interfaceorg.apache.xerces.xni.grammars.XMLGrammarDescription- Returns:
- the type of this grammar
-
getRootName
Description copied from interface:org.apache.xerces.xni.grammars.XMLDTDDescriptionReturn the root name of this DTD.- Specified by:
getRootNamein interfaceorg.apache.xerces.xni.grammars.XMLDTDDescription- Returns:
- the root name of this DTD or null if root name is unknown
-
setRootName
Set the root name -
setPossibleRoots
Set possible roots -
setPossibleRoots
Set possible roots -
equals
Compares this grammar with the given grammar. Currently, we compare as follows: - if grammar type not equal return false immediately - try and find a common root name: - if both have roots, use them - else if one has a root, examine other's possible root's for a match; - else try all combinations - test fExpandedSystemId and fPublicId as above -
hashCode
public int hashCode()Returns the hash code of this grammar Because our .equals method is so complex, we just return a very simple hash that might avoid calls to the equals method a bit...- Overrides:
hashCodein classXMLResourceIdentifierImpl- Returns:
- The hash code
-