xml.StaxWriter.setPrefix

Binds a namespace URI to a prefix.

Syntax

setPrefix(
   prefix STRING,
   ns STRING )
  1. prefix defines the prefix to be bind to the URI, cannot be NULL.
  2. ns defines the namespace URI to be bind to the prefix, cannot be NULL.

Usage

Use this method to bind a namespace URI, specified in ns, to a prefix defined in prefix.

The prefix scope is the current START_ELEMENT / END_ELEMENT pair.

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