xml.DomDocument.declareNamespace

Forces namespace declaration to an XML Element DomNode for a DomDocument object.

Syntax

declareNamespace(
   node xml.DomNode,
   alias STRING,
   ns STRING )
  1. node is the XML Element DomNode that carries the namespace definition.
  2. alias is the alias of the namespace to declare.
  3. ns is the URI of the namespace to declare.

Usage

Forces namespace declaration to an XML Element DomNode for this DomDocument object ; node is the XML Element DomNode that carries the namespace definition; alias is the alias of the namespace to declare, or NULL to declare the default namespace; ns is the URI of the namespace to declare (can only be NULL if alias is NULL).

CAUTION:
Not part of W3C API.

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).