Package org.exolab.castor.xml.dtd
Class DTDdocument
java.lang.Object
org.exolab.castor.xml.dtd.DTDdocument
Implementation of DTD document specification.
- Version:
- $Revision$ $Date: 2003-03-03 00:05:44 -0700 (Mon, 03 Mar 2003) $
- Author:
- Alexander Totok
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
addElement
(Element element) Adds Element Declaration to the document.void
addGeneralEntity
(GeneralEntity generalEntity) Adds General Entity Declaration to the document.void
addNotation
(Notation notation) Adds a Notation Declaration to the document.getElement
(String name) Returns requested Element Declaration.Returns enumeration of the Element declarations in the DTD document.Returns enumeration of the General Entity declarations in the DTD document.getGeneralEntity
(String name) Returns requested Genaral Entity Declaration.getName()
Returns the name of the document.getNotation
(String name) Returns requested Notation Declaration.Returns enumeration of the Notation declarations in the DTD document.
-
Constructor Details
-
DTDdocument
public DTDdocument() -
DTDdocument
Constructor, setting the name of the document.
-
-
Method Details
-
getName
Returns the name of the document. -
addElement
Adds Element Declaration to the document.- Throws:
DTDException
- if an element has no name or there already exists element with the same name in the document.
-
getElement
-
addNotation
Adds a Notation Declaration to the document.- Throws:
DTDException
- if a notation has no name or there already exists notation with the same name in the document.
-
getNotation
-
addGeneralEntity
Adds General Entity Declaration to the document. If there already exists General Entity with the same name in the document, does nothing. -
getGeneralEntity
Returns requested Genaral Entity Declaration.- Returns:
- General Entity Declaration with the given name, null if there is no General Entity with this name in the document.
-
getElements
Returns enumeration of the Element declarations in the DTD document. -
getGeneralEntities
Returns enumeration of the General Entity declarations in the DTD document. -
getNotations
Returns enumeration of the Notation declarations in the DTD document.
-