org.jdom
Class DocType

java.lang.Object
  |
  +--org.jdom.DocType

public class DocType
extends java.lang.Object

DocType represents an XML DOCTYPE declaration.

Version:
1.0
Author:
Brett McLaughlin, Jason Hunter

Field Summary
protected  java.lang.String elementName
          The element being constrained
protected  java.util.List entities
          The entities the DOCTYPE defines
protected  java.util.List notations
          The notations that the DOCTYPE defines
protected  java.lang.String publicID
          The public ID of the DOCTYPE
protected  java.lang.String systemID
          The system ID of the DOCTYPE
 
Constructor Summary
protected DocType()
           Default, no-args constructor for implementations to use if needed.
  DocType(java.lang.String elementName)
           This will create the DocType with the specified element name
  DocType(java.lang.String elementName, java.lang.String systemID)
           This will create the DocType with the specified element name and reference to an external DTD.
  DocType(java.lang.String elementName, java.lang.String publicID, java.lang.String systemID)
           This will create the DocType with the specified element name and a reference to an external DTD.
 
Method Summary
 java.lang.String getElementName()
           This will retrieve the element name being constrained.
 java.lang.String getPublicID()
           This will retrieve the public ID of an externally referenced DTD, or an empty String if none is referenced.
 java.lang.String getSystemID()
           This will retrieve the system ID of an externally referenced DTD, or an empty String if none is referenced.
 DocType setPublicID(java.lang.String publicID)
           This will set the public ID of an externally referenced DTD.
 DocType setSystemID(java.lang.String systemID)
           This will set the system ID of an externally referenced DTD.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

elementName

protected java.lang.String elementName
The element being constrained

entities

protected java.util.List entities
The entities the DOCTYPE defines

notations

protected java.util.List notations
The notations that the DOCTYPE defines

publicID

protected java.lang.String publicID
The public ID of the DOCTYPE

systemID

protected java.lang.String systemID
The system ID of the DOCTYPE
Constructor Detail

DocType

protected DocType()

Default, no-args constructor for implementations to use if needed.


DocType

public DocType(java.lang.String elementName,
               java.lang.String publicID,
               java.lang.String systemID)

This will create the DocType with the specified element name and a reference to an external DTD.

Parameters:
elementName - String name of element being constrained.
publicID - String public ID of referenced DTD
systemID - String system ID of referenced DTD

DocType

public DocType(java.lang.String elementName,
               java.lang.String systemID)

This will create the DocType with the specified element name and reference to an external DTD.

Parameters:
elementName - String name of element being constrained.
systemID - String system ID of referenced DTD

DocType

public DocType(java.lang.String elementName)

This will create the DocType with the specified element name

Parameters:
elementName - String name of element being constrained.
Method Detail

getElementName

public java.lang.String getElementName()

This will retrieve the element name being constrained.

Returns:
String - element name for DOCTYPE

getPublicID

public java.lang.String getPublicID()

This will retrieve the public ID of an externally referenced DTD, or an empty String if none is referenced.

Returns:
String - public ID of referenced DTD.

setPublicID

public DocType setPublicID(java.lang.String publicID)

This will set the public ID of an externally referenced DTD.

Returns:
publicID String public ID of referenced DTD.

getSystemID

public java.lang.String getSystemID()

This will retrieve the system ID of an externally referenced DTD, or an empty String if none is referenced.

Returns:
String - system ID of referenced DTD.

setSystemID

public DocType setSystemID(java.lang.String systemID)

This will set the system ID of an externally referenced DTD.

Returns:
systemID String system ID of referenced DTD.


Copyright © 2000 Brett McLaughlin, Jason Hunter. All Rights Reserved.