xml.DomDocument.createDocumentType

Creates a XML Document Type (DTD) DomNode object for a DomDocument object.

Syntax

createDocumentType(
   name STRING,
   publicID STRING,
   systemID STRING,
   internalSubset STRING )  
  RETURNS xml.DomNode
  1. name defines the name of the document type.
  2. publicID defines the URI of the public identifier.
  3. systemID defines the URL of the system identifier (Specifies the file location of the external DTD subset).
  4. internalSubset defines the internal DTD subset.

Usage

Creates a XML Document Type (DTD) DomNode object for this DomDocument object; name is the name of the document type; publicID is the URI of the public identifier or NULL; systemID is the URL of the system identifier or NULL (Specifies the file location of the external DTD subset); internalSubset is the internal DTD subset or NULL.

Returns a xml.DomNode object, or NULL if internalSubset is malformed.

Important: This method is not part of W3C standard API.

Only internal DTDs are supported.

The public identifier cannot be set without the system identifier.

In case of error, the method throws an exception and sets the STATUS variable. Depending on the error, a human-readable description of the problem is available in the SQLCA.SQLERRM register. See Error handling in GWS calls (STATUS).