package javax.xml.stream;
import javax.xml.namespace.NamespaceContext;
/**
* The XMLStreamWriter interface specifies how to write XML. The XMLStreamWriter does
* not perform well formedness checking on its input. However
* the writeCharacters method is required to escape & , < and >
* For attribute values the writeAttribute method will escape the
* above characters plus " to ensure that all character content
* and attribute values are well formed.
*
* Each NAMESPACE
* and ATTRIBUTE must be individually written.
*
* <table border="1" cellpadding="2" cellspacing="0">
* <thead>
* <tr>
* <th colspan="5">XML Namespaces, <code>javax.xml.stream.isRepairingNamespaces</code> and write method
behaviour</th>
* </tr>
* <tr>
* <th>Method</th> <!-- method -->
* <th colspan="2"><code>isRepairingNamespaces</code> == true</th>
* <th colspan="2"><code>isRepairingNamespaces</code> == false</th>
* </tr>
* <tr>
* <th></th> <!-- method -->
* <th>namespaceURI bound</th>
* <th>namespaceURI unbound</th>
* <th>namespaceURI bound</th>
* <th>namespaceURI unbound</th>
* </tr>
* </thead>
*
* <tbody>
* <tr>
* <th><code>writeAttribute(namespaceURI, localName, value)</code></th>
* <!-- isRepairingNamespaces == true -->
* <td>
* <!-- namespaceURI bound -->
* prefix:localName="value" <sup>[1]</sup>
* </td>
* <td>
* <!-- namespaceURI unbound -->
* xmlns:{generated}="namespaceURI" {generated}:localName="value"
* </td>
* <!-- isRepairingNamespaces == false -->
* <td>
* <!-- namespaceURI bound -->
* prefix:localName="value" <sup>[1]</sup>
* </td>
* <td>
* <!-- namespaceURI unbound -->
* <code>XMLStreamException</code>
* </td>
* </tr>
*
* <tr>
* <th><code>writeAttribute(prefix, namespaceURI, localName, value)</code></th>
* <!-- isRepairingNamespaces == true -->
* <td>
* <!-- namespaceURI bound -->
* bound to same prefix:<br />
* prefix:localName="value" <sup>[1]</sup><br />
* <br />
* bound to different prefix:<br />
* xmlns:{generated}="namespaceURI" {generated}:localName="value"
* </td>
* <td>
* <!-- namespaceURI unbound -->
* xmlns:prefix="namespaceURI" prefix:localName="value" <sup>[3]</sup>
* </td>
* <!-- isRepairingNamespaces == false -->
* <td>
* <!-- namespaceURI bound -->
* bound to same prefix:<br />
* prefix:localName="value" <sup>[1][2]</sup><br />
* <br />
* bound to different prefix:<br />
* <code>XMLStreamException</code><sup>[2]</sup>
* </td>
* <td>
* <!-- namespaceURI unbound -->
* xmlns:prefix="namespaceURI" prefix:localName="value" <sup>[2][5]</sup>
* </td>
* </tr>
*
* <tr>
* <th><code>writeStartElement(namespaceURI, localName)</code><br />
* <br />
* <code>writeEmptyElement(namespaceURI, localName)</code></th>
* <!-- isRepairingNamespaces == true -->
* <td >
* <!-- namespaceURI bound -->
* <prefix:localName> <sup>[1]</sup>
* </td>
* <td>
* <!-- namespaceURI unbound -->
* <{generated}:localName xmlns:{generated}="namespaceURI">
* </td>
=1= |