The DomDocument class / xml.DomDocument methods |
Constructor of a DomDocument with a root namespace-qualified XML root element
xml.DomDocument.createDocumentNS( prefix STRING, name STRING, ns STRING ) RETURNING object xml.DomDocument
Constructor of a xml.DomDocument with a root namespace-qualified XML root element where prefix is the prefix of the XML Element or NULL, name is the name of the XML Element, and ns is the namespace of the XML Element. Returns a DomDocument object.
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).
Create a DomDocument with an initial root node named "List" with abc as the prefix and http://www.mysite.com/xmlapi as the namespace:
xml.domdocument.createDocumentNS("abc","List","http://www.mysite.com/xmlapi")
Produces:
<abc:List xmlns:abc="http://www.mysite.com/xmlapi"> [...] </abc:List>