You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xerces.apache.org by le...@apache.org on 2002/06/12 02:25:25 UTC

cvs commit: xml-xerces/java/src/dom3/org/w3c/dom Attr.java CDATASection.java CharacterData.java Comment.java DOMError.java DOMErrorHandler.java DOMException.java DOMImplementation.java DOMImplementationRegistry.java DOMImplementationSource.java DOMLocator.java Document.java DocumentFragment.java DocumentType.java Element.java Entity.java EntityReference.java NamedNodeMap.java Node.java NodeList.java Notation.java ProcessingInstruction.java Text.java UserDataHandler.java

lehors      2002/06/11 17:25:25

  Added:       java/src/dom3/org/w3c/dom Attr.java CDATASection.java
                        CharacterData.java Comment.java DOMError.java
                        DOMErrorHandler.java DOMException.java
                        DOMImplementation.java
                        DOMImplementationRegistry.java
                        DOMImplementationSource.java DOMLocator.java
                        Document.java DocumentFragment.java
                        DocumentType.java Element.java Entity.java
                        EntityReference.java NamedNodeMap.java Node.java
                        NodeList.java Notation.java
                        ProcessingInstruction.java Text.java
                        UserDataHandler.java
  Log:
  DOM Level 3 interfaces, put in a different hierarchy to allow
  building with this or the DOM Level 2 Core
  
  Revision  Changes    Path
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/Attr.java
  
  Index: Attr.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * The <code>Attr</code> interface represents an attribute in an 
   * <code>Element</code> object. Typically the allowable values for the 
   * attribute are defined in a document type definition.
   * <p><code>Attr</code> objects inherit the <code>Node</code> interface, but 
   * since they are not actually child nodes of the element they describe, the 
   * DOM does not consider them part of the document tree. Thus, the 
   * <code>Node</code> attributes <code>parentNode</code>, 
   * <code>previousSibling</code>, and <code>nextSibling</code> have a 
   * <code>null</code> value for <code>Attr</code> objects. The DOM takes the 
   * view that attributes are properties of elements rather than having a 
   * separate identity from the elements they are associated with; this should 
   * make it more efficient to implement such features as default attributes 
   * associated with all elements of a given type. Furthermore, 
   * <code>Attr</code> nodes may not be immediate children of a 
   * <code>DocumentFragment</code>. However, they can be associated with 
   * <code>Element</code> nodes contained within a 
   * <code>DocumentFragment</code>. In short, users and implementors of the 
   * DOM need to be aware that <code>Attr</code> nodes have some things in 
   * common with other objects inheriting the <code>Node</code> interface, but 
   * they also are quite distinct.
   * <p>The attribute's effective value is determined as follows: if this 
   * attribute has been explicitly assigned any value, that value is the 
   * attribute's effective value; otherwise, if there is a declaration for 
   * this attribute, and that declaration includes a default value, then that 
   * default value is the attribute's effective value; otherwise, the 
   * attribute does not exist on this element in the structure model until it 
   * has been explicitly added. Note that the <code>nodeValue</code> attribute 
   * on the <code>Attr</code> instance can also be used to retrieve the string 
   * version of the attribute's value(s).
   * <p>In XML, where the value of an attribute can contain entity references, 
   * the child nodes of the <code>Attr</code> node may be either 
   * <code>Text</code> or <code>EntityReference</code> nodes (when these are 
   * in use; see the description of <code>EntityReference</code> for 
   * discussion). Because the DOM Core is not aware of attribute types, it 
   * treats all attribute values as simple strings, even if the DTD or schema 
   * declares them as having tokenized types.
   * <p>The DOM implementation does not perform any attribute value normalization
   * . While it is expected that the <code>value</code> and 
   * <code>nodeValue</code> attributes of an <code>Attr</code> node initially 
   * return the normalized value, this may not be the case after mutation. 
   * This is true, independently of whether the mutation is performed by 
   * setting the string value directly or by changing the <code>Attr</code> 
   * child nodes. In particular, this is true when character entity references 
   * are involved, given that they are not represented in the DOM and they 
   * impact attribute value normalization. The properties [attribute type] and 
   * [references] defined in  are not accessible from DOM Level 3 Core. 
   * However,  does provide a way to access the property [attribute type]. 
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface Attr extends Node {
      /**
       * Returns the name of this attribute.
       */
      public String getName();
  
      /**
       * If this attribute was explicitly given a value in the original 
       * document, this is <code>true</code>; otherwise, it is 
       * <code>false</code>. Note that the implementation is in charge of this 
       * attribute, not the user. If the user changes the value of the 
       * attribute (even if it ends up having the same value as the default 
       * value) then the <code>specified</code> flag is automatically flipped 
       * to <code>true</code>. To re-specify the attribute as the default 
       * value from the DTD, the user must delete the attribute. The 
       * implementation will then make a new attribute available with 
       * <code>specified</code> set to <code>false</code> and the default 
       * value (if one exists).
       * <br>In summary: If the attribute has an assigned value in the document 
       * then <code>specified</code> is <code>true</code>, and the value is 
       * the assigned value.If the attribute has no assigned value in the 
       * document and has a default value in the DTD, then 
       * <code>specified</code> is <code>false</code>, and the value is the 
       * default value in the DTD.If the attribute has no assigned value in 
       * the document and has a value of #IMPLIED in the DTD, then the 
       * attribute does not appear in the structure model of the document.If 
       * the <code>ownerElement</code> attribute is <code>null</code> (i.e. 
       * because it was just created or was set to <code>null</code> by the 
       * various removal and cloning operations) <code>specified</code> is 
       * <code>true</code>. 
       * <br> This attribute represents the property [specified] defined . 
       */
      public boolean getSpecified();
  
      /**
       * On retrieval, the value of the attribute is returned as a string. 
       * Character and general entity references are replaced with their 
       * values. See also the method <code>getAttribute</code> on the 
       * <code>Element</code> interface.
       * <br>On setting, this creates a <code>Text</code> node with the unparsed 
       * contents of the string. I.e. any characters that an XML processor 
       * would recognize as markup are instead treated as literal text. See 
       * also the method <code>setAttribute</code> on the <code>Element</code> 
       * interface.
       * <br> If the <code>value</code> does contain the normalized attribute 
       * value, this attribute represents the property [normalized value] 
       * defined in . 
       * @exception DOMException
       *   NO_MODIFICATION_ALLOWED_ERR: Raised when the node is readonly.
       */
      public String getValue();
      /**
       * On retrieval, the value of the attribute is returned as a string. 
       * Character and general entity references are replaced with their 
       * values. See also the method <code>getAttribute</code> on the 
       * <code>Element</code> interface.
       * <br>On setting, this creates a <code>Text</code> node with the unparsed 
       * contents of the string. I.e. any characters that an XML processor 
       * would recognize as markup are instead treated as literal text. See 
       * also the method <code>setAttribute</code> on the <code>Element</code> 
       * interface.
       * <br> If the <code>value</code> does contain the normalized attribute 
       * value, this attribute represents the property [normalized value] 
       * defined in . 
       * @exception DOMException
       *   NO_MODIFICATION_ALLOWED_ERR: Raised when the node is readonly.
       */
      public void setValue(String value)
                              throws DOMException;
  
      /**
       * The <code>Element</code> node this attribute is attached to or 
       * <code>null</code> if this attribute is not in use.
       * <br> This attribute represents the property [owner element] defined in 
       * . 
       * @since DOM Level 2
       */
      public Element getOwnerElement();
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/CDATASection.java
  
  Index: CDATASection.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * CDATA sections are used to escape blocks of text containing characters that 
   * would otherwise be regarded as markup. The only delimiter that is 
   * recognized in a CDATA section is the "]]&gt;" string that ends the CDATA 
   * section. CDATA sections cannot be nested. Their primary purpose is for 
   * including material such as XML fragments, without needing to escape all 
   * the delimiters.
   * <p>The <code>DOMString</code> attribute of the <code>Text</code> node holds 
   * the text that is contained by the CDATA section. Note that this may 
   * contain characters that need to be escaped outside of CDATA sections and 
   * that, depending on the character encoding ("charset") chosen for 
   * serialization, it may be impossible to write out some characters as part 
   * of a CDATA section.
   * <p>The <code>CDATASection</code> interface inherits from the 
   * <code>CharacterData</code> interface through the <code>Text</code> 
   * interface. Adjacent <code>CDATASection</code> nodes are not merged by use 
   * of the <code>normalize</code> method of the <code>Node</code> interface.
   * Because no markup is recognized within a <code>CDATASection</code>, 
   * character numeric references cannot be used as an escape mechanism when 
   * serializing. Therefore, action needs to be taken when serializing a 
   * <code>CDATASection</code> with a character encoding where some of the 
   * contained characters cannot be represented. Failure to do so would not 
   * produce well-formed XML.One potential solution in the serialization 
   * process is to end the CDATA section before the character, output the 
   * character using a character reference or entity reference, and open a new 
   * CDATA section for any further characters in the text node. Note, however, 
   * that some code conversion libraries at the time of writing do not return 
   * an error or exception when a character is missing from the encoding, 
   * making the task of ensuring that data is not corrupted on serialization 
   * more difficult.
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface CDATASection extends Text {
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/CharacterData.java
  
  Index: CharacterData.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * The <code>CharacterData</code> interface extends Node with a set of 
   * attributes and methods for accessing character data in the DOM. For 
   * clarity this set is defined here rather than on each object that uses 
   * these attributes and methods. No DOM objects correspond directly to 
   * <code>CharacterData</code>, though <code>Text</code> and others do 
   * inherit the interface from it. All <code>offsets</code> in this interface 
   * start from <code>0</code>.
   * <p>As explained in the <code>DOMString</code> interface, text strings in 
   * the DOM are represented in UTF-16, i.e. as a sequence of 16-bit units. In 
   * the following, the term 16-bit units is used whenever necessary to 
   * indicate that indexing on CharacterData is done in 16-bit units.
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface CharacterData extends Node {
      /**
       * The character data of the node that implements this interface. The DOM 
       * implementation may not put arbitrary limits on the amount of data 
       * that may be stored in a <code>CharacterData</code> node. However, 
       * implementation limits may mean that the entirety of a node's data may 
       * not fit into a single <code>DOMString</code>. In such cases, the user 
       * may call <code>substringData</code> to retrieve the data in 
       * appropriately sized pieces.
       * <br> When the <code>CharacterData</code> is a <code>Text</code>, or a 
       * <code>CDATASection</code>, this attribute contains the property 
       * [character code] defined in . When the <code>CharacterData</code> is 
       * a <code>Comment</code>, this attribute contains the property 
       * [content] defined by the Comment Information Item in . 
       * @exception DOMException
       *   NO_MODIFICATION_ALLOWED_ERR: Raised when the node is readonly.
       * @exception DOMException
       *   DOMSTRING_SIZE_ERR: Raised when it would return more characters than 
       *   fit in a <code>DOMString</code> variable on the implementation 
       *   platform.
       */
      public String getData()
                              throws DOMException;
      /**
       * The character data of the node that implements this interface. The DOM 
       * implementation may not put arbitrary limits on the amount of data 
       * that may be stored in a <code>CharacterData</code> node. However, 
       * implementation limits may mean that the entirety of a node's data may 
       * not fit into a single <code>DOMString</code>. In such cases, the user 
       * may call <code>substringData</code> to retrieve the data in 
       * appropriately sized pieces.
       * <br> When the <code>CharacterData</code> is a <code>Text</code>, or a 
       * <code>CDATASection</code>, this attribute contains the property 
       * [character code] defined in . When the <code>CharacterData</code> is 
       * a <code>Comment</code>, this attribute contains the property 
       * [content] defined by the Comment Information Item in . 
       * @exception DOMException
       *   NO_MODIFICATION_ALLOWED_ERR: Raised when the node is readonly.
       * @exception DOMException
       *   DOMSTRING_SIZE_ERR: Raised when it would return more characters than 
       *   fit in a <code>DOMString</code> variable on the implementation 
       *   platform.
       */
      public void setData(String data)
                              throws DOMException;
  
      /**
       * The number of 16-bit units that are available through <code>data</code> 
       * and the <code>substringData</code> method below. This may have the 
       * value zero, i.e., <code>CharacterData</code> nodes may be empty.
       */
      public int getLength();
  
      /**
       * Extracts a range of data from the node.
       * @param offset Start offset of substring to extract.
       * @param count The number of 16-bit units to extract.
       * @return The specified substring. If the sum of <code>offset</code> and 
       *   <code>count</code> exceeds the <code>length</code>, then all 16-bit 
       *   units to the end of the data are returned.
       * @exception DOMException
       *   INDEX_SIZE_ERR: Raised if the specified <code>offset</code> is 
       *   negative or greater than the number of 16-bit units in 
       *   <code>data</code>, or if the specified <code>count</code> is 
       *   negative.
       *   <br>DOMSTRING_SIZE_ERR: Raised if the specified range of text does 
       *   not fit into a <code>DOMString</code>.
       */
      public String substringData(int offset, 
                                  int count)
                                  throws DOMException;
  
      /**
       * Append the string to the end of the character data of the node. Upon 
       * success, <code>data</code> provides access to the concatenation of 
       * <code>data</code> and the <code>DOMString</code> specified.
       * @param arg The <code>DOMString</code> to append.
       * @exception DOMException
       *   NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly.
       */
      public void appendData(String arg)
                             throws DOMException;
  
      /**
       * Insert a string at the specified 16-bit unit offset.
       * @param offset The character offset at which to insert.
       * @param arg The <code>DOMString</code> to insert.
       * @exception DOMException
       *   INDEX_SIZE_ERR: Raised if the specified <code>offset</code> is 
       *   negative or greater than the number of 16-bit units in 
       *   <code>data</code>.
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly.
       */
      public void insertData(int offset, 
                             String arg)
                             throws DOMException;
  
      /**
       * Remove a range of 16-bit units from the node. Upon success, 
       * <code>data</code> and <code>length</code> reflect the change.
       * @param offset The offset from which to start removing.
       * @param count The number of 16-bit units to delete. If the sum of 
       *   <code>offset</code> and <code>count</code> exceeds 
       *   <code>length</code> then all 16-bit units from <code>offset</code> 
       *   to the end of the data are deleted.
       * @exception DOMException
       *   INDEX_SIZE_ERR: Raised if the specified <code>offset</code> is 
       *   negative or greater than the number of 16-bit units in 
       *   <code>data</code>, or if the specified <code>count</code> is 
       *   negative.
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly.
       */
      public void deleteData(int offset, 
                             int count)
                             throws DOMException;
  
      /**
       * Replace the characters starting at the specified 16-bit unit offset 
       * with the specified string.
       * @param offset The offset from which to start replacing.
       * @param count The number of 16-bit units to replace. If the sum of 
       *   <code>offset</code> and <code>count</code> exceeds 
       *   <code>length</code>, then all 16-bit units to the end of the data 
       *   are replaced; (i.e., the effect is the same as a <code>remove</code>
       *    method call with the same range, followed by an <code>append</code>
       *    method invocation).
       * @param arg The <code>DOMString</code> with which the range must be 
       *   replaced.
       * @exception DOMException
       *   INDEX_SIZE_ERR: Raised if the specified <code>offset</code> is 
       *   negative or greater than the number of 16-bit units in 
       *   <code>data</code>, or if the specified <code>count</code> is 
       *   negative.
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly.
       */
      public void replaceData(int offset, 
                              int count, 
                              String arg)
                              throws DOMException;
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/Comment.java
  
  Index: Comment.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * This interface inherits from <code>CharacterData</code> and represents the 
   * content of a comment, i.e., all the characters between the starting '
   * <code>&lt;!--</code>' and ending '<code>--&gt;</code>'. Note that this is 
   * the definition of a comment in XML, and, in practice, HTML, although some 
   * HTML tools may implement the full SGML comment structure.
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface Comment extends CharacterData {
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/DOMError.java
  
  Index: DOMError.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * <code>DOMError</code> is an interface that describes an error.
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface DOMError {
      /**
       * The severity of the error described by the <code>DOMError</code> is 
       * warning
       */
      public static final short SEVERITY_WARNING          = 0;
      /**
       * The severity of the error described by the <code>DOMError</code> is 
       * error
       */
      public static final short SEVERITY_ERROR            = 1;
      /**
       * The severity of the error described by the <code>DOMError</code> is 
       * fatal error
       */
      public static final short SEVERITY_FATAL_ERROR      = 2;
      /**
       * The severity of the error, either <code>SEVERITY_WARNING</code>, 
       * <code>SEVERITY_ERROR</code>, or <code>SEVERITY_FATAL_ERROR</code>.
       */
      public short getSeverity();
  
      /**
       * An implementation specific string describing the error that occured.
       */
      public String getMessage();
  
      /**
       * The related platform dependent exception if any.exception is a reserved 
       * word, we need to rename it.Change to "relatedException". (F2F 26 Sep 
       * 2001)
       */
      public Object getRelatedException();
  
      /**
       * The location of the error.
       */
      public DOMLocator getLocation();
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/DOMErrorHandler.java
  
  Index: DOMErrorHandler.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * <code>DOMErrorHandler</code> is a callback interface that the DOM 
   * implementation can call when reporting errors that happens while 
   * processing XML data, or when doing some other processing (e.g. validating 
   * a document).
   * <p>The application that is using the DOM implementation is expected to 
   * implement this interface.How does one register an error handler in the 
   * core? Passed as an argument to super-duper-normalize or registered on the 
   * DOMImplementation?Document interface has an attribute errorHandler.
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface DOMErrorHandler {
      /**
       * This method is called on the error handler when an error occures.
       * @param error The error object that describes the error, this object 
       *   may be reused by the DOM implementation across multiple calls to 
       *   the handleEvent method.
       * @return If the handleError method returns <code>true</code> the DOM 
       *   implementation should continue as if the error didn't happen when 
       *   possible, if the method returns <code>false</code> then the DOM 
       *   implementation should stop the current processing when possible.
       */
      public boolean handleError(DOMError error);
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/DOMException.java
  
  Index: DOMException.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * DOM operations only raise exceptions in "exceptional" circumstances, i.e., 
   * when an operation is impossible to perform (either for logical reasons, 
   * because data is lost, or because the implementation has become unstable). 
   * In general, DOM methods return specific error values in ordinary 
   * processing situations, such as out-of-bound errors when using 
   * <code>NodeList</code>.
   * <p>Implementations should raise other exceptions under other circumstances. 
   * For example, implementations should raise an implementation-dependent 
   * exception if a <code>null</code> argument is passed when <code>null</code>
   *  was not expected.
   * <p>Some languages and object systems do not support the concept of 
   * exceptions. For such systems, error conditions may be indicated using 
   * native error reporting mechanisms. For some bindings, for example, 
   * methods may return error codes similar to those listed in the 
   * corresponding method descriptions.
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public class DOMException extends RuntimeException {
      public DOMException(short code, String message) {
         super(message);
         this.code = code;
      }
      public short   code;
      // ExceptionCode
      /**
       * If index or size is negative, or greater than the allowed value
       */
      public static final short INDEX_SIZE_ERR            = 1;
      /**
       * If the specified range of text does not fit into a DOMString
       */
      public static final short DOMSTRING_SIZE_ERR        = 2;
      /**
       * If any node is inserted somewhere it doesn't belong
       */
      public static final short HIERARCHY_REQUEST_ERR     = 3;
      /**
       * If a node is used in a different document than the one that created it 
       * (that doesn't support it)
       */
      public static final short WRONG_DOCUMENT_ERR        = 4;
      /**
       * If an invalid or illegal character is specified, such as in a name. See 
       * production 2 in the XML specification for the definition of a legal 
       * character, and production 5 for the definition of a legal name 
       * character.
       */
      public static final short INVALID_CHARACTER_ERR     = 5;
      /**
       * If data is specified for a node which does not support data
       */
      public static final short NO_DATA_ALLOWED_ERR       = 6;
      /**
       * If an attempt is made to modify an object where modifications are not 
       * allowed
       */
      public static final short NO_MODIFICATION_ALLOWED_ERR = 7;
      /**
       * If an attempt is made to reference a node in a context where it does 
       * not exist
       */
      public static final short NOT_FOUND_ERR             = 8;
      /**
       * If the implementation does not support the requested type of object or 
       * operation.
       */
      public static final short NOT_SUPPORTED_ERR         = 9;
      /**
       * If an attempt is made to add an attribute that is already in use 
       * elsewhere
       */
      public static final short INUSE_ATTRIBUTE_ERR       = 10;
      /**
       * If an attempt is made to use an object that is not, or is no longer, 
       * usable.
       * @since DOM Level 2
       */
      public static final short INVALID_STATE_ERR         = 11;
      /**
       * If an invalid or illegal string is specified.
       * @since DOM Level 2
       */
      public static final short SYNTAX_ERR                = 12;
      /**
       * If an attempt is made to modify the type of the underlying object.
       * @since DOM Level 2
       */
      public static final short INVALID_MODIFICATION_ERR  = 13;
      /**
       * If an attempt is made to create or change an object in a way which is 
       * incorrect with regard to namespaces.
       * @since DOM Level 2
       */
      public static final short NAMESPACE_ERR             = 14;
      /**
       * If a parameter or an operation is not supported by the underlying 
       * object.
       * @since DOM Level 2
       */
      public static final short INVALID_ACCESS_ERR        = 15;
      /**
       * If a call to a method such as <code>insertBefore</code> or 
       * <code>removeChild</code> would make the <code>Node</code> invalid 
       * with respect to "partial validity", this exception would be raised 
       * and the operation would not be done. This code is used in . Refer to 
       * this specification for further information.
       * @since DOM Level 3
       */
      public static final short VALIDATION_ERR            = 16;
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/DOMImplementation.java
  
  Index: DOMImplementation.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * The <code>DOMImplementation</code> interface provides a number of methods 
   * for performing operations that are independent of any particular instance 
   * of the document object model.
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface DOMImplementation {
      /**
       * Test if the DOM implementation implements a specific feature.
       * @param feature The name of the feature to test (case-insensitive). The 
       *   values used by DOM features are defined throughout the DOM Level 3 
       *   specifications and listed in the  section. The name must be an XML 
       *   name. To avoid possible conflicts, as a convention, names referring 
       *   to features defined outside the DOM specification should be made 
       *   unique.
       * @param version This is the version number of the feature to test. In 
       *   Level 3, the string can be either "3.0", "2.0" or "1.0". If the 
       *   version is <code>null</code> or empty string, supporting any 
       *   version of the feature causes the method to return <code>true</code>
       *   .
       * @return <code>true</code> if the feature is implemented in the 
       *   specified version, <code>false</code> otherwise.
       */
      public boolean hasFeature(String feature, 
                                String version);
  
      /**
       * Creates an empty <code>DocumentType</code> node. Entity declarations 
       * and notations are not made available. Entity reference expansions and 
       * default attribute additions do not occur. It is expected that a 
       * future version of the DOM will provide a way for populating a 
       * <code>DocumentType</code>.
       * @param qualifiedName The qualified name of the document type to be 
       *   created.
       * @param publicId The external subset public identifier.
       * @param systemId The external subset system identifier.
       * @return A new <code>DocumentType</code> node with 
       *   <code>Node.ownerDocument</code> set to <code>null</code>.
       * @exception DOMException
       *   INVALID_CHARACTER_ERR: Raised if the specified qualified name 
       *   contains an illegal character.
       *   <br>NAMESPACE_ERR: Raised if the <code>qualifiedName</code> is 
       *   malformed.
       *   <br>NOT_SUPPORTED_ERR: May be raised by DOM implementations which do 
       *   not support the <code>"XML"</code> feature, if they choose not to 
       *   support this method. Other features introduced in the future, by 
       *   the DOM WG or in extensions defined by other groups, may also 
       *   demand support for this method; please consult the definition of 
       *   the feature to see if it requires this method. 
       * @since DOM Level 2
       */
      public DocumentType createDocumentType(String qualifiedName, 
                                             String publicId, 
                                             String systemId)
                                             throws DOMException;
  
      /**
       * Creates a DOM Document object of the specified type with its document 
       * element.
       * <br>Note that based on the <code>DocumentType</code> given to create 
       * the document, the implementation may instantiate specialized 
       * <code>Document</code> objects that support additional features than 
       * the "Core", such as "HTML" . On the other hand, setting the 
       * <code>DocumentType</code> after the document was created makes this 
       * very unlikely to happen. Alternatively, specialized 
       * <code>Document</code> creation methods, such as 
       * <code>createHTMLDocument</code> , can be used to obtain specific 
       * types of <code>Document</code> objects.
       * @param namespaceURI The namespace URI of the document element to 
       *   create or <code>null</code>.
       * @param qualifiedName The qualified name of the document element to be 
       *   created or <code>null</code>.
       * @param doctype The type of document to be created or <code>null</code>.
       *   When <code>doctype</code> is not <code>null</code>, its 
       *   <code>Node.ownerDocument</code> attribute is set to the document 
       *   being created.
       * @return A new <code>Document</code> object with its document element. 
       *   If the <code>NamespaceURI</code>, <code>qualifiedName</code>, and 
       *   <code>doctype</code> are <code>null</code>, the returned 
       *   <code>Document</code> is empty with no document element.
       * @exception DOMException
       *   INVALID_CHARACTER_ERR: Raised if the specified qualified name 
       *   contains an illegal character.
       *   <br>NAMESPACE_ERR: Raised if the <code>qualifiedName</code> is 
       *   malformed, if the <code>qualifiedName</code> has a prefix and the 
       *   <code>namespaceURI</code> is <code>null</code>, or if the 
       *   <code>qualifiedName</code> is <code>null</code> and the 
       *   <code>namespaceURI</code> is different from <code>null</code>, or 
       *   if the <code>qualifiedName</code> has a prefix that is "xml" and 
       *   the <code>namespaceURI</code> is different from "
       *   http://www.w3.org/XML/1998/namespace" , or if the DOM 
       *   implementation does not support the <code>"XML"</code> feature but 
       *   a non-null namespace URI was provided, since namespaces were 
       *   defined by XML.
       *   <br>WRONG_DOCUMENT_ERR: Raised if <code>doctype</code> has already 
       *   been used with a different document or was created from a different 
       *   implementation.
       *   <br>NOT_SUPPORTED_ERR: May be raised by DOM implementations which do 
       *   not support the "XML" feature, if they choose not to support this 
       *   method. Other features introduced in the future, by the DOM WG or 
       *   in extensions defined by other groups, may also demand support for 
       *   this method; please consult the definition of the feature to see if 
       *   it requires this method. 
       * @since DOM Level 2
       */
      public Document createDocument(String namespaceURI, 
                                     String qualifiedName, 
                                     DocumentType doctype)
                                     throws DOMException;
  
      /**
       * This method makes available a <code>DOMImplementation</code>'s 
       * specialized interface (see ).
       * @param feature The name of the feature requested (case-insensitive).
       * @return Returns an alternate <code>DOMImplementation</code> which 
       *   implements the specialized APIs of the specified feature, if any, 
       *   or <code>null</code> if there is no alternate 
       *   <code>DOMImplementation</code> object which implements interfaces 
       *   associated with that feature. Any alternate 
       *   <code>DOMImplementation</code> returned by this method must 
       *   delegate to the primary core <code>DOMImplementation</code> and not 
       *   return results inconsistent with the primary 
       *   <code>DOMImplementation</code>
       * @since DOM Level 3
       */
      public DOMImplementation getInterface(String feature);
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/DOMImplementationRegistry.java
  
  Index: DOMImplementationRegistry.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  
  package org.w3c.dom; 
  
  import java.util.StringTokenizer;
  import java.util.Vector;
  
  /**
   * This class holds the list of registered DOMImplementations. It is first
   * initialized based on the content of the space separated list of classnames
   * contained in the System Property "org.w3c.dom.DOMImplementationSourceList".
   *
   * <p>Subsequently, additional sources can be registered and implementations
   * can be queried based on a list of requested features.
   *
   * <p>This provides an application with an implementation independent starting
   * point.
   *
   * @see DOMImplementation
   * @see DOMImplementationSource
   */
  public class DOMImplementationRegistry 
  { 
  
      // The system property to specify the DOMImplementationSource class names. 
      public static String PROPERTY = "org.w3c.dom.DOMImplementationSourceList";
  
      private static Vector sources = new Vector();
      private static boolean initialized = false;
  
      private static void initialize() throws ClassNotFoundException,
          InstantiationException, IllegalAccessException
      {
          initialized = true;
          String p = System.getProperty(PROPERTY);
          if (p == null) {
              return;
          }
          StringTokenizer st = new StringTokenizer(p);
          while (st.hasMoreTokens()) {
              Object source = Class.forName(st.nextToken()).newInstance();
              sources.addElement(source);
          }
      }
  
      /**
       * Return the first registered implementation that has the desired features,
       * or null if none is found.
       *
       * @param features A string that specifies which features are required.
       *                 This is a space separated list in which each feature is
       *                 specified by its name optionally followed by a space
       *                 and a version number.
       *                 This is something like: "XML 1.0 Traversal Events 2.0"
       * @return An implementation that has the desired features, or
       *   <code>null</code> if this source has none.
       */
      public static DOMImplementation getDOMImplementation(String features)
          throws ClassNotFoundException,
          InstantiationException, IllegalAccessException
      {
          if (!initialized) {
              initialize();
          }
          int len = sources.size(); 
          for (int i = 0; i < len; i++) {
              DOMImplementationSource source =
                  (DOMImplementationSource) sources.elementAt(i);
  
              DOMImplementation impl = source.getDOMImplementation(features);
              if (impl != null) {
                  return impl;
              }
          }
          return null;
      }
  
      /**
       * Register an implementation.
       */
      public static void addSource(DOMImplementationSource s)
          throws ClassNotFoundException,
          InstantiationException, IllegalAccessException
      {
          if (!initialized) {
              initialize();
          }
          sources.addElement(s);
          // update system property accordingly
          StringBuffer b = new StringBuffer(System.getProperty(PROPERTY));
          b.append(" " + s.getClass().getName());
          System.setProperty(PROPERTY, b.toString());
      }
  }
    
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/DOMImplementationSource.java
  
  Index: DOMImplementationSource.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * This interface permits a DOM implementer to supply one or more 
   * implementations, based upon requested features. Each implemented 
   * <code>DOMImplementationSource</code> object is listed in the 
   * binding-specific list of available sources so that its 
   * <code>DOMImplementation</code> objects are made available.
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface DOMImplementationSource {
      /**
       * A method to request a DOM implementation.
       * @param features A string that specifies which features are required. 
       *   This is a space separated list in which each feature is specified 
       *   by its name optionally followed by a space and a version number. 
       *   This is something like: "XML 1.0 Traversal Events 2.0"
       * @return An implementation that has the desired features, or 
       *   <code>null</code> if this source has none.
       */
      public DOMImplementation getDOMImplementation(String features);
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/DOMLocator.java
  
  Index: DOMLocator.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * <code>DOMLocator</code> is an interface that describes a location (e.g. 
   * where an error occured).
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface DOMLocator {
      /**
       * The line number where the error occured, or -1 if there is no line 
       * number available.
       */
      public int getLineNumber();
  
      /**
       * The column number where the error occured, or -1 if there is no column 
       * number available.
       */
      public int getColumnNumber();
  
      /**
       * The byte or character offset into the input source, if we're parsing a 
       * file or a byte stream then this will be the byte offset into that 
       * stream, but if a character media is parsed then the offset will be 
       * the character offset. The value is <code>-1</code> if there is no 
       * offset available.
       */
      public int getOffset();
  
      /**
       * The DOM Node where the error occured, or null if there is no Node 
       * available.
       */
      public Node getErrorNode();
  
      /**
       * The URI where the error occured, or null if there is no URI available.
       */
      public String getUri();
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/Document.java
  
  Index: Document.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * The <code>Document</code> interface represents the entire HTML or XML 
   * document. Conceptually, it is the root of the document tree, and provides 
   * the primary access to the document's data.
   * <p>Since elements, text nodes, comments, processing instructions, etc. 
   * cannot exist outside the context of a <code>Document</code>, the 
   * <code>Document</code> interface also contains the factory methods needed 
   * to create these objects. The <code>Node</code> objects created have a 
   * <code>ownerDocument</code> attribute which associates them with the 
   * <code>Document</code> within whose context they were created.
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface Document extends Node {
      /**
       * The Document Type Declaration (see <code>DocumentType</code>) 
       * associated with this document. For HTML documents as well as XML 
       * documents without a document type declaration this returns 
       * <code>null</code>.
       * <br>This provides direct access to the <code>DocumentType</code> node, 
       * child node of this <code>Document</code>. This node can be set at 
       * document creation time and later changed through the use of child 
       * nodes manipulation methods, such as <code>insertBefore</code>, or 
       * <code>replaceChild</code>. Note, however, that while some 
       * implementations may instantiate different types of 
       * <code>Document</code> objects supporting additional features than the 
       * "Core", such as "HTML" , based on the <code>DocumentType</code> 
       * specified at creation time, changing it afterwards is very unlikely 
       * to result in a change of the features supported.
       * @version DOM Level 3
       */
      public DocumentType getDoctype();
  
      /**
       * The <code>DOMImplementation</code> object that handles this document. A 
       * DOM application may use objects from multiple implementations.
       */
      public DOMImplementation getImplementation();
  
      /**
       * This is a convenience attribute that allows direct access to the child 
       * node that is the document element of the document.
       * <br> This attribute represents the property [document element] defined 
       * in . 
       */
      public Element getDocumentElement();
  
      /**
       * Creates an element of the type specified. Note that the instance 
       * returned implements the <code>Element</code> interface, so attributes 
       * can be specified directly on the returned object.
       * <br>In addition, if there are known attributes with default values, 
       * <code>Attr</code> nodes representing them are automatically created 
       * and attached to the element.
       * <br>To create an element with a qualified name and namespace URI, use 
       * the <code>createElementNS</code> method.
       * @param tagName The name of the element type to instantiate. For XML, 
       *   this is case-sensitive, otherwise it depends on the case-sentivity 
       *   of the markup language in use. In that case, the name is mapped to 
       *   the canonical form of that markup by the DOM implementation.
       * @return A new <code>Element</code> object with the 
       *   <code>nodeName</code> attribute set to <code>tagName</code>, and 
       *   <code>localName</code>, <code>prefix</code>, and 
       *   <code>namespaceURI</code> set to <code>null</code>.
       * @exception DOMException
       *   INVALID_CHARACTER_ERR: Raised if the specified name contains an 
       *   illegal character.
       */
      public Element createElement(String tagName)
                                   throws DOMException;
  
      /**
       * Creates an empty <code>DocumentFragment</code> object.
       * @return A new <code>DocumentFragment</code>.
       */
      public DocumentFragment createDocumentFragment();
  
      /**
       * Creates a <code>Text</code> node given the specified string.
       * @param data The data for the node.
       * @return The new <code>Text</code> object.
       */
      public Text createTextNode(String data);
  
      /**
       * Creates a <code>Comment</code> node given the specified string.
       * @param data The data for the node.
       * @return The new <code>Comment</code> object.
       */
      public Comment createComment(String data);
  
      /**
       * Creates a <code>CDATASection</code> node whose value is the specified 
       * string.
       * @param data The data for the <code>CDATASection</code> contents.
       * @return The new <code>CDATASection</code> object.
       * @exception DOMException
       *   NOT_SUPPORTED_ERR: Raised if this document is an HTML document.
       */
      public CDATASection createCDATASection(String data)
                                             throws DOMException;
  
      /**
       * Creates a <code>ProcessingInstruction</code> node given the specified 
       * name and data strings.
       * @param target The target part of the processing instruction.
       * @param data The data for the node.
       * @return The new <code>ProcessingInstruction</code> object.
       * @exception DOMException
       *   INVALID_CHARACTER_ERR: Raised if the specified target contains an 
       *   illegal character.
       *   <br>NOT_SUPPORTED_ERR: Raised if this document is an HTML document.
       */
      public ProcessingInstruction createProcessingInstruction(String target, 
                                                               String data)
                                                               throws DOMException;
  
      /**
       * Creates an <code>Attr</code> of the given name. Note that the 
       * <code>Attr</code> instance can then be set on an <code>Element</code> 
       * using the <code>setAttributeNode</code> method. 
       * <br>To create an attribute with a qualified name and namespace URI, use 
       * the <code>createAttributeNS</code> method.
       * @param name The name of the attribute.
       * @return A new <code>Attr</code> object with the <code>nodeName</code> 
       *   attribute set to <code>name</code>, and <code>localName</code>, 
       *   <code>prefix</code>, and <code>namespaceURI</code> set to 
       *   <code>null</code>. The value of the attribute is the empty string.
       * @exception DOMException
       *   INVALID_CHARACTER_ERR: Raised if the specified name contains an 
       *   illegal character.
       */
      public Attr createAttribute(String name)
                                  throws DOMException;
  
      /**
       * Creates an <code>EntityReference</code> object. In addition, if the 
       * referenced entity is known, the child list of the 
       * <code>EntityReference</code> node is made the same as that of the 
       * corresponding <code>Entity</code> node.If any descendant of the 
       * <code>Entity</code> node has an unbound namespace prefix, the 
       * corresponding descendant of the created <code>EntityReference</code> 
       * node is also unbound; (its <code>namespaceURI</code> is 
       * <code>null</code>). The DOM Level 2 does not support any mechanism to 
       * resolve namespace prefixes.
       * @param name The name of the entity to reference.
       * @return The new <code>EntityReference</code> object.
       * @exception DOMException
       *   INVALID_CHARACTER_ERR: Raised if the specified name contains an 
       *   illegal character.
       *   <br>NOT_SUPPORTED_ERR: Raised if this document is an HTML document.
       */
      public EntityReference createEntityReference(String name)
                                                   throws DOMException;
  
      /**
       * Returns a <code>NodeList</code> of all the <code>Elements</code> with a 
       * given tag name in document order.
       * @param tagname The name of the tag to match on. The special value "*" 
       *   matches all tags. For XML, this is case-sensitive, otherwise it 
       *   depends on the case-sentivity of the markup language in use.
       * @return A new <code>NodeList</code> object containing all the matched 
       *   <code>Elements</code>.
       */
      public NodeList getElementsByTagName(String tagname);
  
      /**
       * Imports a node from another document to this document. The returned 
       * node has no parent; (<code>parentNode</code> is <code>null</code>). 
       * The source node is not altered or removed from the original document; 
       * this method creates a new copy of the source node.
       * <br>For all nodes, importing a node creates a node object owned by the 
       * importing document, with attribute values identical to the source 
       * node's <code>nodeName</code> and <code>nodeType</code>, plus the 
       * attributes related to namespaces (<code>prefix</code>, 
       * <code>localName</code>, and <code>namespaceURI</code>). As in the 
       * <code>cloneNode</code> operation, the source node is not altered. 
       * User data associated to the imported node is not carried over. 
       * However, if any <code>UserDataHandlers</code> has been specified 
       * along with the associated data these handlers will be called with the 
       * appropriate parameters before this method returns.
       * <br>Additional information is copied as appropriate to the 
       * <code>nodeType</code>, attempting to mirror the behavior expected if 
       * a fragment of XML or HTML source was copied from one document to 
       * another, recognizing that the two documents may have different DTDs 
       * in the XML case. The following list describes the specifics for each 
       * type of node. 
       * <dl>
       * <dt>ATTRIBUTE_NODE</dt>
       * <dd>The <code>ownerElement</code> attribute 
       * is set to <code>null</code> and the <code>specified</code> flag is 
       * set to <code>true</code> on the generated <code>Attr</code>. The 
       * descendants of the source <code>Attr</code> are recursively imported 
       * and the resulting nodes reassembled to form the corresponding subtree.
       * Note that the <code>deep</code> parameter has no effect on 
       * <code>Attr</code> nodes; they always carry their children with them 
       * when imported.</dd>
       * <dt>DOCUMENT_FRAGMENT_NODE</dt>
       * <dd>If the <code>deep</code> option 
       * was set to <code>true</code>, the descendants of the source 
       * <code>DocumentFragment</code> are recursively imported and the 
       * resulting nodes reassembled under the imported 
       * <code>DocumentFragment</code> to form the corresponding subtree. 
       * Otherwise, this simply generates an empty 
       * <code>DocumentFragment</code>.</dd>
       * <dt>DOCUMENT_NODE</dt>
       * <dd><code>Document</code> 
       * nodes cannot be imported.</dd>
       * <dt>DOCUMENT_TYPE_NODE</dt>
       * <dd><code>DocumentType</code> 
       * nodes cannot be imported.</dd>
       * <dt>ELEMENT_NODE</dt>
       * <dd>Specified attribute nodes of the 
       * source element are imported, and the generated <code>Attr</code> 
       * nodes are attached to the generated <code>Element</code>. Default 
       * attributes are not copied, though if the document being imported into 
       * defines default attributes for this element name, those are assigned. 
       * If the <code>importNode</code> <code>deep</code> parameter was set to 
       * <code>true</code>, the descendants of the source element are 
       * recursively imported and the resulting nodes reassembled to form the 
       * corresponding subtree.</dd>
       * <dt>ENTITY_NODE</dt>
       * <dd><code>Entity</code> nodes can be 
       * imported, however in the current release of the DOM the 
       * <code>DocumentType</code> is readonly. Ability to add these imported 
       * nodes to a <code>DocumentType</code> will be considered for addition 
       * to a future release of the DOM.On import, the <code>publicId</code>, 
       * <code>systemId</code>, and <code>notationName</code> attributes are 
       * copied. If a <code>deep</code> import is requested, the descendants 
       * of the the source <code>Entity</code> are recursively imported and 
       * the resulting nodes reassembled to form the corresponding subtree.</dd>
       * <dt>
       * ENTITY_REFERENCE_NODE</dt>
       * <dd>Only the <code>EntityReference</code> itself is 
       * copied, even if a <code>deep</code> import is requested, since the 
       * source and destination documents might have defined the entity 
       * differently. If the document being imported into provides a 
       * definition for this entity name, its value is assigned.</dd>
       * <dt>NOTATION_NODE</dt>
       * <dd>
       * <code>Notation</code> nodes can be imported, however in the current 
       * release of the DOM the <code>DocumentType</code> is readonly. Ability 
       * to add these imported nodes to a <code>DocumentType</code> will be 
       * considered for addition to a future release of the DOM.On import, the 
       * <code>publicId</code> and <code>systemId</code> attributes are copied.
       * Note that the <code>deep</code> parameter has no effect on this type 
       * of nodes since they cannot have any children.</dd>
       * <dt>
       * PROCESSING_INSTRUCTION_NODE</dt>
       * <dd>The imported node copies its 
       * <code>target</code> and <code>data</code> values from those of the 
       * source node.Note that the <code>deep</code> parameter has no effect 
       * on this type of nodes since they cannot have any children.</dd>
       * <dt>TEXT_NODE, 
       * CDATA_SECTION_NODE, COMMENT_NODE</dt>
       * <dd>These three types of nodes inheriting 
       * from <code>CharacterData</code> copy their <code>data</code> and 
       * <code>length</code> attributes from those of the source node.Note 
       * that the <code>deep</code> parameter has no effect on these types of 
       * nodes since they cannot have any children.</dd>
       * </dl> 
       * @param importedNode The node to import.
       * @param deep If <code>true</code>, recursively import the subtree under 
       *   the specified node; if <code>false</code>, import only the node 
       *   itself, as explained above. This has no effect on nodes that cannot 
       *   have any children, and on <code>Attr</code>, and 
       *   <code>EntityReference</code> nodes.
       * @return The imported node that belongs to this <code>Document</code>.
       * @exception DOMException
       *   NOT_SUPPORTED_ERR: Raised if the type of node being imported is not 
       *   supported.
       *   <br>INVALID_CHARACTER_ERR: Raised if one the imported names contain 
       *   an illegal character. This may happen when importing an XML 1.1  
       *   element into an XML 1.0 document, for instance.
       * @since DOM Level 2
       */
      public Node importNode(Node importedNode, 
                             boolean deep)
                             throws DOMException;
  
      /**
       * Creates an element of the given qualified name and namespace URI.
       * <br>Per , applications must use the value null as the namespaceURI 
       * parameter for methods if they wish to have no namespace.
       * @param namespaceURI The namespace URI of the element to create.
       * @param qualifiedName The qualified name of the element type to 
       *   instantiate.
       * @return A new <code>Element</code> object with the following 
       *   attributes:
       * <table border='1'>
       * <tr>
       * <th>Attribute</th>
       * <th>Value</th>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'><code>Node.nodeName</code></td>
       * <td valign='top' rowspan='1' colspan='1'>
       *   <code>qualifiedName</code></td>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'><code>Node.namespaceURI</code></td>
       * <td valign='top' rowspan='1' colspan='1'>
       *   <code>namespaceURI</code></td>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'><code>Node.prefix</code></td>
       * <td valign='top' rowspan='1' colspan='1'>prefix, extracted 
       *   from <code>qualifiedName</code>, or <code>null</code> if there is 
       *   no prefix</td>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'><code>Node.localName</code></td>
       * <td valign='top' rowspan='1' colspan='1'>local name, extracted from 
       *   <code>qualifiedName</code></td>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'><code>Element.tagName</code></td>
       * <td valign='top' rowspan='1' colspan='1'>
       *   <code>qualifiedName</code></td>
       * </tr>
       * </table>
       * @exception DOMException
       *   INVALID_CHARACTER_ERR: Raised if the specified qualified name 
       *   contains an illegal character, per the XML 1.0 specification .
       *   <br>NAMESPACE_ERR: Raised if the <code>qualifiedName</code> is 
       *   malformed per the Namespaces in XML specification, if the 
       *   <code>qualifiedName</code> has a prefix and the 
       *   <code>namespaceURI</code> is <code>null</code>, or if the 
       *   <code>qualifiedName</code> has a prefix that is "xml" and the 
       *   <code>namespaceURI</code> is different from "
       *   http://www.w3.org/XML/1998/namespace" .
       *   <br>NOT_SUPPORTED_ERR: Always thrown if the current document does not 
       *   support the <code>"XML"</code> feature, since namespaces were 
       *   defined by XML.
       * @since DOM Level 2
       */
      public Element createElementNS(String namespaceURI, 
                                     String qualifiedName)
                                     throws DOMException;
  
      /**
       * Creates an attribute of the given qualified name and namespace URI.
       * <br>Per , applications must use the value null as the namespaceURI 
       * parameter for methods if they wish to have no namespace.
       * @param namespaceURI The namespace URI of the attribute to create.
       * @param qualifiedName The qualified name of the attribute to 
       *   instantiate.
       * @return A new <code>Attr</code> object with the following attributes:
       * <table border='1'>
       * <tr>
       * <th>
       *   Attribute</th>
       * <th>Value</th>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'><code>Node.nodeName</code></td>
       * <td valign='top' rowspan='1' colspan='1'>qualifiedName</td>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'>
       *   <code>Node.namespaceURI</code></td>
       * <td valign='top' rowspan='1' colspan='1'><code>namespaceURI</code></td>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'>
       *   <code>Node.prefix</code></td>
       * <td valign='top' rowspan='1' colspan='1'>prefix, extracted from 
       *   <code>qualifiedName</code>, or <code>null</code> if there is no 
       *   prefix</td>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'><code>Node.localName</code></td>
       * <td valign='top' rowspan='1' colspan='1'>local name, extracted from 
       *   <code>qualifiedName</code></td>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'><code>Attr.name</code></td>
       * <td valign='top' rowspan='1' colspan='1'>
       *   <code>qualifiedName</code></td>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'><code>Node.nodeValue</code></td>
       * <td valign='top' rowspan='1' colspan='1'>the empty 
       *   string</td>
       * </tr>
       * </table>
       * @exception DOMException
       *   INVALID_CHARACTER_ERR: Raised if the specified qualified name 
       *   contains an illegal character, per the XML 1.0 specification .
       *   <br>NAMESPACE_ERR: Raised if the <code>qualifiedName</code> is 
       *   malformed per the Namespaces in XML specification, if the 
       *   <code>qualifiedName</code> has a prefix and the 
       *   <code>namespaceURI</code> is <code>null</code>, if the 
       *   <code>qualifiedName</code> has a prefix that is "xml" and the 
       *   <code>namespaceURI</code> is different from "
       *   http://www.w3.org/XML/1998/namespace", or if the 
       *   <code>qualifiedName</code>, or its prefix, is "xmlns" and the 
       *   <code>namespaceURI</code> is different from "
       *   http://www.w3.org/2000/xmlns/".
       *   <br>NOT_SUPPORTED_ERR: Always thrown if the current document does not 
       *   support the <code>"XML"</code> feature, since namespaces were 
       *   defined by XML.
       * @since DOM Level 2
       */
      public Attr createAttributeNS(String namespaceURI, 
                                    String qualifiedName)
                                    throws DOMException;
  
      /**
       * Returns a <code>NodeList</code> of all the <code>Elements</code> with a 
       * given local name and namespace URI in document order.
       * @param namespaceURI The namespace URI of the elements to match on. The 
       *   special value "*" matches all namespaces.
       * @param localName The local name of the elements to match on. The 
       *   special value "*" matches all local names.
       * @return A new <code>NodeList</code> object containing all the matched 
       *   <code>Elements</code>.
       * @since DOM Level 2
       */
      public NodeList getElementsByTagNameNS(String namespaceURI, 
                                             String localName);
  
      /**
       * Returns the <code>Element</code> whose <code>ID</code> is given by 
       * <code>elementId</code>. If no such element exists, returns 
       * <code>null</code>. Behavior is not defined if more than one element 
       * has this <code>ID</code>. The DOM implementation must have 
       * information that says which attributes are of type ID. Attributes 
       * with the name "ID" are not of type ID unless so defined. 
       * Implementations that do not know whether attributes are of type ID or 
       * not are expected to return <code>null</code>. 
       * @param elementId The unique <code>id</code> value for an element.
       * @return The matching element.
       * @since DOM Level 2
       */
      public Element getElementById(String elementId);
  
      /**
       * An attribute specifying the actual encoding of this document. This is 
       * <code>null</code> otherwise.
       * <br> This attribute represents the property [character encoding scheme] 
       * defined in . 
       * @since DOM Level 3
       */
      public String getActualEncoding();
      /**
       * An attribute specifying the actual encoding of this document. This is 
       * <code>null</code> otherwise.
       * <br> This attribute represents the property [character encoding scheme] 
       * defined in . 
       * @since DOM Level 3
       */
      public void setActualEncoding(String actualEncoding);
  
      /**
       * An attribute specifying, as part of the XML declaration, the encoding 
       * of this document. This is <code>null</code> when unspecified.
       * @since DOM Level 3
       */
      public String getEncoding();
      /**
       * An attribute specifying, as part of the XML declaration, the encoding 
       * of this document. This is <code>null</code> when unspecified.
       * @since DOM Level 3
       */
      public void setEncoding(String encoding);
  
      /**
       * An attribute specifying, as part of the XML declaration, whether this 
       * document is standalone.
       * <br> This attribute represents the property [standalone] defined in . 
       * @since DOM Level 3
       */
      public boolean getStandalone();
      /**
       * An attribute specifying, as part of the XML declaration, whether this 
       * document is standalone.
       * <br> This attribute represents the property [standalone] defined in . 
       * @since DOM Level 3
       */
      public void setStandalone(boolean standalone);
  
      /**
       * An attribute specifying, as part of the XML declaration, the version 
       * number of this document. This is <code>null</code> when unspecified.
       * <br> This attribute represents the property [version] defined in . 
       * @exception DOMException
       *   NOT_SUPPORTED_ERR: Raised if the version is set to a value that is 
       *   not supported by this <code>Document</code>.
       * @since DOM Level 3
       */
      public String getVersion();
      /**
       * An attribute specifying, as part of the XML declaration, the version 
       * number of this document. This is <code>null</code> when unspecified.
       * <br> This attribute represents the property [version] defined in . 
       * @exception DOMException
       *   NOT_SUPPORTED_ERR: Raised if the version is set to a value that is 
       *   not supported by this <code>Document</code>.
       * @since DOM Level 3
       */
      public void setVersion(String version)
                                    throws DOMException;
  
      /**
       * An attribute specifying whether errors checking is enforced or not. 
       * When set to <code>false</code>, the implementation is free to not 
       * test every possible error case normally defined on DOM operations, 
       * and not raise any <code>DOMException</code>. In case of error, the 
       * behavior is undefined. This attribute is <code>true</code> by 
       * defaults.
       * @since DOM Level 3
       */
      public boolean getStrictErrorChecking();
      /**
       * An attribute specifying whether errors checking is enforced or not. 
       * When set to <code>false</code>, the implementation is free to not 
       * test every possible error case normally defined on DOM operations, 
       * and not raise any <code>DOMException</code>. In case of error, the 
       * behavior is undefined. This attribute is <code>true</code> by 
       * defaults.
       * @since DOM Level 3
       */
      public void setStrictErrorChecking(boolean strictErrorChecking);
  
      /**
       * This attribute allows applications to specify a 
       * <code>DOMErrorHandler</code> to be called in the event that an error 
       * is encountered while performing an operation on a document. Note that 
       * not all methods use this mechanism, see the description of each 
       * method for details.
       * @since DOM Level 3
       */
      public DOMErrorHandler getErrorHandler();
      /**
       * This attribute allows applications to specify a 
       * <code>DOMErrorHandler</code> to be called in the event that an error 
       * is encountered while performing an operation on a document. Note that 
       * not all methods use this mechanism, see the description of each 
       * method for details.
       * @since DOM Level 3
       */
      public void setErrorHandler(DOMErrorHandler errorHandler);
  
      /**
       * The location of the document or <code>null</code> if undefined.
       * <br>Beware that when the <code>Document</code> supports the feature 
       * "HTML" , the href attribute of the HTML BASE element takes precedence 
       * over this attribute.
       * @since DOM Level 3
       */
      public String getDocumentURI();
      /**
       * The location of the document or <code>null</code> if undefined.
       * <br>Beware that when the <code>Document</code> supports the feature 
       * "HTML" , the href attribute of the HTML BASE element takes precedence 
       * over this attribute.
       * @since DOM Level 3
       */
      public void setDocumentURI(String documentURI);
  
      /**
       * Changes the <code>ownerDocument</code> of a node, its children, as well 
       * as the attached attribute nodes if there are any. If the node has a 
       * parent it is first removed from its parent child list. This 
       * effectively allows moving a subtree from one document to another. The 
       * following list describes the specifics for each type of node. 
       * <dl>
       * <dt>
       * ATTRIBUTE_NODE</dt>
       * <dd>The <code>ownerElement</code> attribute is set to 
       * <code>null</code> and the <code>specified</code> flag is set to 
       * <code>true</code> on the adopted <code>Attr</code>. The descendants 
       * of the source <code>Attr</code> are recursively adopted.</dd>
       * <dt>
       * DOCUMENT_FRAGMENT_NODE</dt>
       * <dd>The descendants of the source node are 
       * recursively adopted.</dd>
       * <dt>DOCUMENT_NODE</dt>
       * <dd><code>Document</code> nodes cannot 
       * be adopted.</dd>
       * <dt>DOCUMENT_TYPE_NODE</dt>
       * <dd><code>DocumentType</code> nodes cannot 
       * be adopted.</dd>
       * <dt>ELEMENT_NODE</dt>
       * <dd>Specified attribute nodes of the source 
       * element are adopted, and the generated <code>Attr</code> nodes. 
       * Default attributes are discarded, though if the document being 
       * adopted into defines default attributes for this element name, those 
       * are assigned. The descendants of the source element are recursively 
       * adopted.</dd>
       * <dt>ENTITY_NODE</dt>
       * <dd><code>Entity</code> nodes cannot be adopted.</dd>
       * <dt>
       * ENTITY_REFERENCE_NODE</dt>
       * <dd>Only the <code>EntityReference</code> node 
       * itself is adopted, the descendants are discarded, since the source 
       * and destination documents might have defined the entity differently. 
       * If the document being imported into provides a definition for this 
       * entity name, its value is assigned.</dd>
       * <dt>NOTATION_NODE</dt>
       * <dd><code>Notation</code> 
       * nodes cannot be adopted.</dd>
       * <dt>PROCESSING_INSTRUCTION_NODE, TEXT_NODE, 
       * CDATA_SECTION_NODE, COMMENT_NODE</dt>
       * <dd>These nodes can all be adopted. No 
       * specifics.</dd>
       * </dl> Should this method simply return null when it fails? How 
       * "exceptional" is failure for this method?Stick with raising 
       * exceptions only in exceptional circumstances, return null on failure 
       * (F2F 19 Jun 2000).Can an entity node really be adopted?No, neither 
       * can Notation nodes (Telcon 13 Dec 2000).Does this affect keys and 
       * hashCode's of the adopted subtree nodes?If so, what about 
       * readonly-ness of key and hashCode?if not, would appendChild affect 
       * keys/hashCodes or would it generate exceptions if key's are duplicate?
       * Both keys and hashcodes have been dropped.
       * @param source The node to move into this document.
       * @return The adopted node, or <code>null</code> if this operation 
       *   fails, such as when the source node comes from a different 
       *   implementation.
       * @exception DOMException
       *   NOT_SUPPORTED_ERR: Raised if the source node is of type 
       *   <code>DOCUMENT</code>, <code>DOCUMENT_TYPE</code>.
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised when the source node is 
       *   readonly.
       * @since DOM Level 3
       */
      public Node adoptNode(Node source)
                            throws DOMException;
  
      /**
       * This method acts as if the document was going through a save and load 
       * cycle, putting the document in a "normal" form. The actual result 
       * depends on the features being set and governing what operations 
       * actually take place. See <code>setNormalizationFeature</code> for 
       * details.
       * <br>Noticeably this method normalizes <code>Text</code> nodes, makes 
       * the document "namespace wellformed", according to the algorithm 
       * described below in pseudo code, by adding missing namespace 
       * declaration attributes and adding or changing namespace prefixes, 
       * updates the replacement tree of <code>EntityReference</code> nodes, 
       * normalizes attribute values, etc.
       * <br>Mutation events, when supported, are generated to reflect the 
       * changes occuring on the document.
       * <br>See  for details on how namespace declaration attributes and 
       * prefixes are normalized.Any other name? Joe proposes 
       * normalizeNamespaces.normalizeDocument. (F2F 26 Sep 2001)How specific 
       * should this be? Should we not even specify that this should be done 
       * by walking down the tree?Very. See above.What does this do on 
       * attribute nodes?Doesn't do anything (F2F 1 Aug 2000).How does it work 
       * with entity reference subtree which may be broken?This doesn't affect 
       * entity references which are not visited in this operation (F2F 1 Aug 
       * 2000).Should this really be on Node?Yes, but this only works on 
       * Document, Element, and DocumentFragment. On other types it is a 
       * no-op. (F2F 1 Aug 2000).No. Now that it does much more than simply 
       * fixing namespaces it only makes sense on Document (F2F 26 Sep 2001).
       * What happens with read-only nodes?What/how errors should be reported? 
       * Are there any?Through the error reporter.Should this be optional?No.
       * What happens with regard to mutation events?Mutation events are fired 
       * as expected. (F2F 28 Feb 2002).
       * @since DOM Level 3
       */
      public void normalizeDocument();
  
      /**
       * Query whether setting a feature to a specific value is supported.
       * <br>The feature name has the same form as a DOM <code>hasFeature</code> 
       * string.
       * @param name The name of the feature to check.
       * @param state The requested state of the feature (<code>true</code> or 
       *   <code>false</code>).
       * @return <code>true</code> if the feature could be successfully set to 
       *   the specified value, or <code>false</code> if the feature is not 
       *   recognized or the requested value is not supported. This does not 
       *   change the current value of the feature itself.
       * @since DOM Level 3
       */
      public boolean canSetNormalizationFeature(String name, 
                                                boolean state);
  
      /**
       * Set the state of a feature.Need to specify the list of features.
       * <br>Feature names are valid XML names. Implementation specific features 
       * (extensions) should choose an implementation specific prefix to avoid 
       * name collisions. The following lists feature names that are 
       * recognized by all implementations. However, it is sometimes possible 
       * for a <code>Document</code> to recognize a feature but not to support 
       * setting its value. The following list of recognized features 
       * indicates the definitions of each feature state, if setting the state 
       * to <code>true</code> or <code>false</code> must be supported or is 
       * optional and, which state is the default one:
       * <dl>
       * <dt>
       * <code>"canonical-form"</code></dt>
       * <dd>
       * <dl>
       * <dt><code>true</code></dt>
       * <dd>[optional]Canonicalize 
       * the document according to the rules specified in . Note that this is 
       * limited to what can be represented in the DOM. In particular, there 
       * is no way to specify the order of the attributes in the DOM. What 
       * happen to other features? are they ignored? if yes, how do you know 
       * if a feature is ignored? </dd>
       * <dt><code>false</code></dt>
       * <dd>[required] (default)Do not 
       * canonicalize the document.</dd>
       * </dl></dd>
       * <dt><code>"cdata-sections"</code></dt>
       * <dd>
       * <dl>
       * <dt>
       * <code>true</code></dt>
       * <dd>[required] (default)Keep <code>CDATASection</code> 
       * nodes in the document.Name does not work really well in this case. 
       * ALH suggests renaming this to "cdata-sections". It works for both 
       * load and save.Renamed as suggested. (Telcon 27 Jan 2002).</dd>
       * <dt>
       * <code>false</code></dt>
       * <dd>[optional]Transform <code>CDATASection</code> nodes 
       * in the document into <code>Text</code> nodes. The new 
       * <code>Text</code> node is then combined with any adjacent 
       * <code>Text</code> node.</dd>
       * </dl></dd>
       * <dt><code>"comments"</code></dt>
       * <dd>
       * <dl>
       * <dt><code>true</code></dt>
       * <dd>[
       * required] (default)Keep <code>Comment</code> nodes in the document.</dd>
       * <dt>
       * <code>false</code></dt>
       * <dd>[required]Discard <code>Comment</code> nodes in the 
       * Document.</dd>
       * </dl></dd>
       * <dt><code>"datatype-normalization"</code></dt>
       * <dd>
       * <dl>
       * <dt><code>true</code></dt>
       * <dd>[
       * required]Let the validation process do its datatype normalization 
       * that is defined in the used schema language. Note that this does not 
       * affect the DTD normalization operation which always takes place, in 
       * accordance to .We should define "datatype normalization".DTD 
       * normalization always apply because it's part of XML 1.0. Clarify the 
       * spec. (Telcon 27 Jan 2002).</dd>
       * <dt><code>false</code></dt>
       * <dd>[required] (default)
       * Disable datatype normalization. The XML 1.0 attribute value 
       * normalization always occurs though.</dd>
       * </dl></dd>
       * <dt>
       * <code>"discard-default-content"</code></dt>
       * <dd>
       * <dl>
       * <dt><code>true</code></dt>
       * <dd>[required] (
       * default)Use whatever information available to the implementation 
       * (i.e. XML schema, DTD, the <code>specified</code> flag on 
       * <code>Attr</code> nodes, and so on) to decide what attributes and 
       * content should be discarded or not. Note that the 
       * <code>specified</code> flag on <code>Attr</code> nodes in itself is 
       * not always reliable, it is only reliable when it is set to 
       * <code>false</code> since the only case where it can be set to 
       * <code>false</code> is if the attribute was created by the 
       * implementation. The default content won't be removed if an 
       * implementation does not have any information available.How does 
       * exactly work? What's the comment about level 1 implementations?Remove 
       * "Level 1" (Telcon 16 Jan 2002).</dd>
       * <dt><code>false</code></dt>
       * <dd>[required]Keep all 
       * attributes and all content.</dd>
       * </dl></dd>
       * <dt><code>"entities"</code></dt>
       * <dd>
       * <dl>
       * <dt><code>true</code></dt>
       * <dd>[
       * required] (default)Keep <code>EntityReference</code> and 
       * <code>Entity</code> nodes in the document.How does that interact with 
       * expand-entity-references? ALH suggests consolidating the two to a 
       * single feature called "entity-references" that is used both for load 
       * and save.Consolidate both features into a single feature called 
       * 'entities'. (Telcon 27 Jan 2002).</dd>
       * <dt><code>false</code></dt>
       * <dd>[optional]Remove 
       * all <code>EntityReference</code> and <code>Entity</code> nodes from 
       * the document, putting the entity expansions directly in their place. 
       * <code>Text</code> nodes are into "normal" form. Only 
       * <code>EntityReference</code> nodes to non-defined entities are kept 
       * in the document.</dd>
       * </dl></dd>
       * <dt><code>"infoset"</code></dt>
       * <dd>
       * <dl>
       * <dt><code>true</code></dt>
       * <dd>[optional]Only 
       * keep in the document the information defined in the XML Information 
       * Set .This forces the following features to <code>false</code>: 
       * <code>namespace-declarations</code>, <code>validate-if-schema</code>, 
       * <code>entities</code>, <code>cdata-sections</code>.This forces the 
       * following features to <code>true</code>: 
       * <code>datatype-normalization</code>, 
       * <code>whitespace-in-element-content</code>, <code>comments</code>.
       * Other features are not changed unless explicity specified in the 
       * description of the features. Note that querying this feature with 
       * <code>getFeature</code> returns <code>true</code> only if the 
       * individual features specified above are appropriately set.Name 
       * doesn't work well here. ALH suggests renaming this to 
       * limit-to-infoset or match-infoset, something like that.Renamed 
       * 'infoset' (Telcon 27 Jan 2002).</dd>
       * <dt><code>false</code></dt>
       * <dd>Setting 
       * <code>infoset</code> to <code>false</code> has no effect.Shouldn't we 
       * change this to setting the relevant options back to their default 
       * value?No, this is more like a convenience function, it's better to 
       * keep it simple. (F2F 28 Feb 2002).</dd>
       * </dl></dd>
       * <dt>
       * <code>"namespace-declarations"</code></dt>
       * <dd>
       * <dl>
       * <dt><code>true</code></dt>
       * <dd>[required] (
       * default)Include namespace declaration attributes, specified or 
       * defaulted from the schema or the DTD, in the document. See also the 
       * section Declaring Namespaces in .</dd>
       * <dt><code>false</code></dt>
       * <dd>[optional]Discard 
       * all namespace declaration attributes. The Namespace prefixes are 
       * retained even if this feature is set to <code>false</code>.</dd>
       * </dl></dd>
       * <dt>
       * <code>"normalize-characters"</code></dt>
       * <dd>
       * <dl>
       * <dt><code>true</code></dt>
       * <dd>[optional]Perform 
       * the W3C Text Normalization of the characters  in the document. </dd>
       * <dt>
       * <code>false</code></dt>
       * <dd>[required] (default)Do not perform character 
       * normalization.</dd>
       * </dl></dd>
       * <dt><code>"split-cdata-sections"</code></dt>
       * <dd>
       * <dl>
       * <dt><code>true</code></dt>
       * <dd>[
       * required] (default)Split CDATA sections containing the CDATA section 
       * termination marker ']]&gt;'. When a CDATA section is split a warning 
       * is issued.</dd>
       * <dt><code>false</code></dt>
       * <dd>[required]Signal an error if a 
       * <code>CDATASection</code> contains an unrepresentable character.</dd>
       * </dl></dd>
       * <dt>
       * <code>"validate"</code></dt>
       * <dd>
       * <dl>
       * <dt><code>true</code></dt>
       * <dd>[optional]Require the 
       * validation against a schema (i.e. XML schema, DTD, , any other type 
       * or representation of schema) of the document as it is being 
       * normalized as defined by . If validation errors are found, or no 
       * schema was found, the error handler is notified. Note also that no 
       * datatype normalization (i.e. non-XML 1.0 normalization) is done 
       * according to the schema used unless the feature 
       * <code>datatype-normalization</code> is <code>true</code>.  
       * <code>validate-if-schema</code> and <code>validate</code> are 
       * mutually exclusive, setting one of them to <code>true</code> will set 
       * the other one to <code>false</code>. </dd>
       * <dt><code>false</code></dt>
       * <dd>[required] (
       * default) Only XML 1.0 non-validating processing must be done. Note 
       * that validation might still happen if <code>validate-if-schema</code> 
       * is <code>true</code>. </dd>
       * </dl></dd>
       * <dt><code>"validate-if-schema"</code></dt>
       * <dd>
       * <dl>
       * <dt>
       * <code>true</code></dt>
       * <dd>[optional]Enable validation only if a declaration 
       * for the document element can be found (independently of where it is 
       * found, i.e. XML schema, DTD, , or any other type or representation of 
       * schema). If validation errors are found, the error handler is 
       * notified. Note also that no datatype normalization (i.e. non-XML 1.0 
       * normalization) is done according to the schema used unless the 
       * feature <code>datatype-normalization</code> is <code>true</code>. 
       * <code>validate-if-schema</code> and <code>validate</code> are 
       * mutually exclusive, setting one of them to <code>true</code> will set 
       * the other one to <code>false</code>. How does that interact with the 
       * notion of active AS?If document has AS model, than it "has a schema", 
       * thus validation will be performed against the active AS model. 
       * (Telcon 16 Jan 2002).</dd>
       * <dt><code>false</code></dt>
       * <dd>[required] (default)No 
       * validation should be performed if the document has a schema. Note 
       * that validation must still happen if <code>validate</code> is 
       * <code>true</code>. </dd>
       * </dl></dd>
       * <dt><code>"whitespace-in-element-content"</code></dt>
       * <dd>
       * <dl>
       * <dt>
       * <code>true</code></dt>
       * <dd>[required] (default)Keep all white spaces in the 
       * document. How does this feature interact with <code>"validate"</code> 
       * and <code>Text.isWhitespaceInElementContent</code>. </dd>
       * <dt><code>false</code></dt>
       * <dd>
       * [optional]Discard white space in element content while normalizing. 
       * The implementation is expected to use the 
       * <code>isWhitespaceInElementContent</code> flag on <code>Text</code> 
       * nodes to determine if a text node should be written out or not.</dd>
       * </dl></dd>
       * </dl>
       * @param name The name of the feature to set.
       * @param state The requested state of the feature (<code>true</code> or 
       *   <code>false</code>).
       * @exception DOMException
       *   NOT_SUPPORTED_ERR: Raised when the feature name is recognized but the 
       *   requested value cannot be set.
       *   <br>NOT_FOUND_ERR: Raised when the feature name is not recognized.
       * @since DOM Level 3
       */
      public void setNormalizationFeature(String name, 
                                          boolean state)
                                          throws DOMException;
  
      /**
       * Look up the value of a feature.
       * <br>The feature name has the same form as a DOM <code>hasFeature</code> 
       * string. The recognized features are the same as the ones defined for 
       * <code>setNormalizationFeature</code>.
       * @param name The name of the feature to look up.
       * @return The current state of the feature (<code>true</code> or 
       *   <code>false</code>).
       * @exception DOMException
       *   NOT_FOUND_ERR: Raised when the feature name is not recognized.
       * @since DOM Level 3
       */
      public boolean getNormalizationFeature(String name)
                                             throws DOMException;
  
      /**
       * Rename an existing node. When possible this simply changes the name of 
       * the given node, otherwise this creates a new node with the specified 
       * name and replaces the existing node with the new node as described 
       * below. This only applies to nodes of type <code>ELEMENT_NODE</code> 
       * and <code>ATTRIBUTE_NODE</code>.
       * <br>When a new node is created, the following operations are performed: 
       * the new node is created, any registered event listener is registered 
       * on the new node, any user data attached to the old node is removed 
       * from that node, the old node is removed from its parent if it has 
       * one, the children are moved to the new node, if the renamed node is 
       * an <code>Element</code> its attributes are moved to the new node, the 
       * new node is inserted at the position the old node used to have in its 
       * parent's child nodes list if it has one, the user data that was 
       * attached to the old node is attach to the new node, the user data 
       * event <code>NODE_RENAMED</code> is fired.
       * <br>When the node being renamed is an <code>Attr</code> that is 
       * attached to an <code>Element</code>, the node is first removed from 
       * the <code>Element</code> attributes map. Then, once renamed, either 
       * by modifying the existing node or creating a new one as described 
       * above, it is put back.
       * <br>In addition, when the implementation supports the feature 
       * "MutationEvents", each mutation operation involved in this method 
       * fires the appropriate event, and in the end the event 
       * <code>ElementNameChanged</code> or <code>AttributeNameChanged</code> 
       * is fired.Should this throw a HIERARCHY_REQUEST_ERR?No. (F2F 28 Feb 
       * 2002).
       * @param n The node to rename.
       * @param namespaceURI The new namespaceURI.
       * @param name The new qualified name.
       * @return The renamed node. This is either the specified node or the new 
       *   node that was created to replace the specified node.
       * @exception DOMException
       *   NOT_SUPPORTED_ERR: Raised when the type of the specified node is 
       *   neither <code>ELEMENT_NODE</code> nor <code>ATTRIBUTE_NODE</code>.
       *   <br>WRONG_DOCUMENT_ERR: Raised when the specified node was created 
       *   from a different document than this document.
       *   <br>NAMESPACE_ERR: Raised if the <code>qualifiedName</code> is 
       *   malformed per the Namespaces in XML specification, if the 
       *   <code>qualifiedName</code> has a prefix and the 
       *   <code>namespaceURI</code> is <code>null</code>, or if the 
       *   <code>qualifiedName</code> has a prefix that is "xml" and the 
       *   <code>namespaceURI</code> is different from "
       *   http://www.w3.org/XML/1998/namespace" . Also raised, when the node 
       *   being renamed is an attribute, if the <code>qualifiedName</code>, 
       *   or its prefix, is "xmlns" and the <code>namespaceURI</code> is 
       *   different from "http://www.w3.org/2000/xmlns/".
       * @since DOM Level 3
       */
      public Node renameNode(Node n, 
                             String namespaceURI, 
                             String name)
                             throws DOMException;
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/DocumentFragment.java
  
  Index: DocumentFragment.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * <code>DocumentFragment</code> is a "lightweight" or "minimal" 
   * <code>Document</code> object. It is very common to want to be able to 
   * extract a portion of a document's tree or to create a new fragment of a 
   * document. Imagine implementing a user command like cut or rearranging a 
   * document by moving fragments around. It is desirable to have an object 
   * which can hold such fragments and it is quite natural to use a Node for 
   * this purpose. While it is true that a <code>Document</code> object could 
   * fulfill this role, a <code>Document</code> object can potentially be a 
   * heavyweight object, depending on the underlying implementation. What is 
   * really needed for this is a very lightweight object. 
   * <code>DocumentFragment</code> is such an object.
   * <p>Furthermore, various operations -- such as inserting nodes as children 
   * of another <code>Node</code> -- may take <code>DocumentFragment</code> 
   * objects as arguments; this results in all the child nodes of the 
   * <code>DocumentFragment</code> being moved to the child list of this node.
   * <p>The children of a <code>DocumentFragment</code> node are zero or more 
   * nodes representing the tops of any sub-trees defining the structure of 
   * the document. <code>DocumentFragment</code> nodes do not need to be 
   * well-formed XML documents (although they do need to follow the rules 
   * imposed upon well-formed XML parsed entities, which can have multiple top 
   * nodes). For example, a <code>DocumentFragment</code> might have only one 
   * child and that child node could be a <code>Text</code> node. Such a 
   * structure model represents neither an HTML document nor a well-formed XML 
   * document.
   * <p>When a <code>DocumentFragment</code> is inserted into a 
   * <code>Document</code> (or indeed any other <code>Node</code> that may 
   * take children) the children of the <code>DocumentFragment</code> and not 
   * the <code>DocumentFragment</code> itself are inserted into the 
   * <code>Node</code>. This makes the <code>DocumentFragment</code> very 
   * useful when the user wishes to create nodes that are siblings; the 
   * <code>DocumentFragment</code> acts as the parent of these nodes so that 
   * the user can use the standard methods from the <code>Node</code> 
   * interface, such as <code>insertBefore</code> and <code>appendChild</code>.
   *  The properties [notations] and [unparsed entities] defined by the 
   * Document Information Item in  are accessible through the 
   * <code>DocumentType</code> interface. The property [all declarations 
   * processed] is not accessible through the DOM API. 
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface DocumentFragment extends Node {
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/DocumentType.java
  
  Index: DocumentType.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * Each <code>Document</code> has a <code>doctype</code> attribute whose value 
   * is either <code>null</code> or a <code>DocumentType</code> object. The 
   * <code>DocumentType</code> interface in the DOM Core provides an interface 
   * to the list of entities that are defined for the document, and little 
   * else because the effect of namespaces and the various XML schema efforts 
   * on DTD representation are not clearly understood as of this writing.
   * <p>The DOM Level 2 doesn't support editing <code>DocumentType</code> nodes. 
   * The property [children] defined by the Document Type Declaration 
   * Information Item in  is not accessible from DOM Level 3 Core. 
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface DocumentType extends Node {
      /**
       * The name of DTD; i.e., the name immediately following the 
       * <code>DOCTYPE</code> keyword.
       */
      public String getName();
  
      /**
       * A <code>NamedNodeMap</code> containing the general entities, both 
       * external and internal, declared in the DTD. Parameter entities are 
       * not contained. Duplicates are discarded. For example in: 
       * <pre>&lt;!DOCTYPE 
       * ex SYSTEM "ex.dtd" [ &lt;!ENTITY foo "foo"&gt; &lt;!ENTITY bar 
       * "bar"&gt; &lt;!ENTITY bar "bar2"&gt; &lt;!ENTITY % baz "baz"&gt; 
       * ]&gt; &lt;ex/&gt;</pre>
       *  the interface provides access to <code>foo</code> 
       * and the first declaration of <code>bar</code> but not the second 
       * declaration of <code>bar</code> or <code>baz</code>. Every node in 
       * this map also implements the <code>Entity</code> interface.
       * <br>The DOM Level 2 does not support editing entities, therefore 
       * <code>entities</code> cannot be altered in any way.
       */
      public NamedNodeMap getEntities();
  
      /**
       * A <code>NamedNodeMap</code> containing the notations declared in the 
       * DTD. Duplicates are discarded. Every node in this map also implements 
       * the <code>Notation</code> interface.
       * <br>The DOM Level 2 does not support editing notations, therefore 
       * <code>notations</code> cannot be altered in any way.
       * <br> This attribute represents the property [notations] defined by the 
       * Document Information Item in . 
       */
      public NamedNodeMap getNotations();
  
      /**
       * The public identifier of the external subset.
       * <br> This attribute represents the property [public identifier] defined 
       * by the Document Type Declaration Information Item in . 
       * @since DOM Level 2
       */
      public String getPublicId();
  
      /**
       * The system identifier of the external subset. This may be an absolute 
       * URI or not.
       * <br> This attribute represents the property [system identifier] defined 
       * by the Document Type Declaration Information Item in . 
       * @since DOM Level 2
       */
      public String getSystemId();
  
      /**
       * The internal subset as a string, or <code>null</code> if there is none. 
       * This is does not contain the delimiting square brackets.The actual 
       * content returned depends on how much information is available to the 
       * implementation. This may vary depending on various parameters, 
       * including the XML processor used to build the document.
       * @since DOM Level 2
       */
      public String getInternalSubset();
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/Element.java
  
  Index: Element.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * The <code>Element</code> interface represents an element in an HTML or XML 
   * document. Elements may have attributes associated with them; since the 
   * <code>Element</code> interface inherits from <code>Node</code>, the 
   * generic <code>Node</code> interface attribute <code>attributes</code> may 
   * be used to retrieve the set of all attributes for an element. There are 
   * methods on the <code>Element</code> interface to retrieve either an 
   * <code>Attr</code> object by name or an attribute value by name. In XML, 
   * where an attribute value may contain entity references, an 
   * <code>Attr</code> object should be retrieved to examine the possibly 
   * fairly complex sub-tree representing the attribute value. On the other 
   * hand, in HTML, where all attributes have simple string values, methods to 
   * directly access an attribute value can safely be used as a convenience.In 
   * DOM Level 2, the method <code>normalize</code> is inherited from the 
   * <code>Node</code> interface where it was moved. The property [in-scope 
   * namespaces] defined in  are not accessible from DOM Level 3 Core. 
   * However,  does provide a way to access the property [in-scope namespaces].
   *  
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface Element extends Node {
      /**
       * The name of the element. For example, in: 
       * <pre> &lt;elementExample 
       * id="demo"&gt; ... &lt;/elementExample&gt; , </pre>
       *  <code>tagName</code> has 
       * the value <code>"elementExample"</code>. Note that this is 
       * case-preserving in XML, as are all of the operations of the DOM. The 
       * HTML DOM returns the <code>tagName</code> of an HTML element in the 
       * canonical uppercase form, regardless of the case in the source HTML 
       * document.
       */
      public String getTagName();
  
      /**
       * Retrieves an attribute value by name.
       * @param name The name of the attribute to retrieve.
       * @return The <code>Attr</code> value as a string, or the empty string 
       *   if that attribute does not have a specified or default value.
       */
      public String getAttribute(String name);
  
      /**
       * Adds a new attribute. If an attribute with that name is already present 
       * in the element, its value is changed to be that of the value 
       * parameter. This value is a simple string; it is not parsed as it is 
       * being set. So any markup (such as syntax to be recognized as an 
       * entity reference) is treated as literal text, and needs to be 
       * appropriately escaped by the implementation when it is written out. 
       * In order to assign an attribute value that contains entity 
       * references, the user must create an <code>Attr</code> node plus any 
       * <code>Text</code> and <code>EntityReference</code> nodes, build the 
       * appropriate subtree, and use <code>setAttributeNode</code> to assign 
       * it as the value of an attribute.
       * <br>To set an attribute with a qualified name and namespace URI, use 
       * the <code>setAttributeNS</code> method.
       * @param name The name of the attribute to create or alter.
       * @param value Value to set in string form.
       * @exception DOMException
       *   INVALID_CHARACTER_ERR: Raised if the specified name contains an 
       *   illegal character.
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly.
       */
      public void setAttribute(String name, 
                               String value)
                               throws DOMException;
  
      /**
       * Removes an attribute by name. If the removed attribute is known to have 
       * a default value, an attribute immediately appears containing the 
       * default value as well as the corresponding namespace URI, local name, 
       * and prefix when applicable. If the attribute does not have a 
       * specified or default value, calling this method has no effect.
       * <br>To remove an attribute by local name and namespace URI, use the 
       * <code>removeAttributeNS</code> method.
       * @param name The name of the attribute to remove.
       * @exception DOMException
       *   NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly.
       */
      public void removeAttribute(String name)
                                  throws DOMException;
  
      /**
       * Retrieves an attribute node by name.
       * <br>To retrieve an attribute node by qualified name and namespace URI, 
       * use the <code>getAttributeNodeNS</code> method.
       * @param name The name (<code>nodeName</code>) of the attribute to 
       *   retrieve.
       * @return The <code>Attr</code> node with the specified name (
       *   <code>nodeName</code>) or <code>null</code> if there is no such 
       *   attribute.
       */
      public Attr getAttributeNode(String name);
  
      /**
       * Adds a new attribute node. If an attribute with that name (
       * <code>nodeName</code>) is already present in the element, it is 
       * replaced by the new one. Replacing an attribute node by itself has no 
       * effect.
       * <br>To add a new attribute node with a qualified name and namespace 
       * URI, use the <code>setAttributeNodeNS</code> method.
       * @param newAttr The <code>Attr</code> node to add to the attribute list.
       * @return If the <code>newAttr</code> attribute replaces an existing 
       *   attribute, the replaced <code>Attr</code> node is returned, 
       *   otherwise <code>null</code> is returned.
       * @exception DOMException
       *   WRONG_DOCUMENT_ERR: Raised if <code>newAttr</code> was created from a 
       *   different document than the one that created the element.
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly.
       *   <br>INUSE_ATTRIBUTE_ERR: Raised if <code>newAttr</code> is already an 
       *   attribute of another <code>Element</code> object. The DOM user must 
       *   explicitly clone <code>Attr</code> nodes to re-use them in other 
       *   elements.
       */
      public Attr setAttributeNode(Attr newAttr)
                                   throws DOMException;
  
      /**
       * Removes the specified attribute node. If the removed <code>Attr</code> 
       * has a default value it is immediately replaced. The replacing 
       * attribute has the same namespace URI and local name, as well as the 
       * original prefix, when applicable.
       * @param oldAttr The <code>Attr</code> node to remove from the attribute 
       *   list.
       * @return The <code>Attr</code> node that was removed.
       * @exception DOMException
       *   NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly.
       *   <br>NOT_FOUND_ERR: Raised if <code>oldAttr</code> is not an attribute 
       *   of the element.
       */
      public Attr removeAttributeNode(Attr oldAttr)
                                      throws DOMException;
  
      /**
       * Returns a <code>NodeList</code> of all descendant <code>Elements</code> 
       * with a given tag name, in document order.
       * @param name The name of the tag to match on. The special value "*" 
       *   matches all tags.
       * @return A list of matching <code>Element</code> nodes.
       */
      public NodeList getElementsByTagName(String name);
  
      /**
       * Retrieves an attribute value by local name and namespace URI.
       * <br>Documents which do not support the "XML" feature will permit only 
       * the DOM Level 1 calls for creating/setting elements and attributes. 
       * Hence, if you specify a non-null namespace URI, these DOMs will never 
       * find a matching node.
       * <br>Per , applications must use the value null as the namespaceURI 
       * parameter for methods if they wish to have no namespace.
       * @param namespaceURI The namespace URI of the attribute to retrieve.
       * @param localName The local name of the attribute to retrieve.
       * @return The <code>Attr</code> value as a string, or the empty string 
       *   if that attribute does not have a specified or default value.
       * @since DOM Level 2
       */
      public String getAttributeNS(String namespaceURI, 
                                   String localName);
  
      /**
       * Adds a new attribute. If an attribute with the same local name and 
       * namespace URI is already present on the element, its prefix is 
       * changed to be the prefix part of the <code>qualifiedName</code>, and 
       * its value is changed to be the <code>value</code> parameter. This 
       * value is a simple string; it is not parsed as it is being set. So any 
       * markup (such as syntax to be recognized as an entity reference) is 
       * treated as literal text, and needs to be appropriately escaped by the 
       * implementation when it is written out. In order to assign an 
       * attribute value that contains entity references, the user must create 
       * an <code>Attr</code> node plus any <code>Text</code> and 
       * <code>EntityReference</code> nodes, build the appropriate subtree, 
       * and use <code>setAttributeNodeNS</code> or 
       * <code>setAttributeNode</code> to assign it as the value of an 
       * attribute.
       * <br>Per , applications must use the value null as the namespaceURI 
       * parameter for methods if they wish to have no namespace.
       * @param namespaceURI The namespace URI of the attribute to create or 
       *   alter.
       * @param qualifiedName The qualified name of the attribute to create or 
       *   alter.
       * @param value The value to set in string form.
       * @exception DOMException
       *   INVALID_CHARACTER_ERR: Raised if the specified qualified name 
       *   contains an illegal character, per the XML 1.0 specification .
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly.
       *   <br>NAMESPACE_ERR: Raised if the <code>qualifiedName</code> is 
       *   malformed per the Namespaces in XML specification, if the 
       *   <code>qualifiedName</code> has a prefix and the 
       *   <code>namespaceURI</code> is <code>null</code>, if the 
       *   <code>qualifiedName</code> has a prefix that is "xml" and the 
       *   <code>namespaceURI</code> is different from "
       *   http://www.w3.org/XML/1998/namespace", or if the 
       *   <code>qualifiedName</code>, or its prefix, is "xmlns" and the 
       *   <code>namespaceURI</code> is different from "
       *   http://www.w3.org/2000/xmlns/".
       *   <br>NOT_SUPPORTED_ERR: Always thrown if the current document does not 
       *   support the <code>"XML"</code> feature, since namespaces were 
       *   defined by XML.
       * @since DOM Level 2
       */
      public void setAttributeNS(String namespaceURI, 
                                 String qualifiedName, 
                                 String value)
                                 throws DOMException;
  
      /**
       * Removes an attribute by local name and namespace URI. If the removed 
       * attribute has a default value it is immediately replaced. The 
       * replacing attribute has the same namespace URI and local name, as 
       * well as the original prefix. If the attribute does not have a 
       * specified or default value, calling this method has no effect.
       * <br>Documents which do not support the "XML" feature will permit only 
       * the DOM Level 1 calls for creating/setting elements and attributes. 
       * Hence, if you specify a non-null namespace URI, these DOMs will never 
       * find a matching node.
       * <br>Per , applications must use the value null as the namespaceURI 
       * parameter for methods if they wish to have no namespace.
       * @param namespaceURI The namespace URI of the attribute to remove.
       * @param localName The local name of the attribute to remove.
       * @exception DOMException
       *   NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly.
       * @since DOM Level 2
       */
      public void removeAttributeNS(String namespaceURI, 
                                    String localName)
                                    throws DOMException;
  
      /**
       * Retrieves an <code>Attr</code> node by local name and namespace URI.
       * <br>Documents which do not support the "XML" feature will permit only 
       * the DOM Level 1 calls for creating/setting elements and attributes. 
       * Hence, if you specify a non-null namespace URI, these DOMs will never 
       * find a matching node.
       * <br>Per , applications must use the value null as the namespaceURI 
       * parameter for methods if they wish to have no namespace.
       * @param namespaceURI The namespace URI of the attribute to retrieve.
       * @param localName The local name of the attribute to retrieve.
       * @return The <code>Attr</code> node with the specified attribute local 
       *   name and namespace URI or <code>null</code> if there is no such 
       *   attribute.
       * @since DOM Level 2
       */
      public Attr getAttributeNodeNS(String namespaceURI, 
                                     String localName);
  
      /**
       * Adds a new attribute. If an attribute with that local name and that 
       * namespace URI is already present in the element, it is replaced by 
       * the new one. Replacing an attribute node by itself has no effect.
       * <br>Per , applications must use the value null as the namespaceURI 
       * parameter for methods if they wish to have no namespace.
       * @param newAttr The <code>Attr</code> node to add to the attribute list.
       * @return If the <code>newAttr</code> attribute replaces an existing 
       *   attribute with the same local name and namespace URI, the replaced 
       *   <code>Attr</code> node is returned, otherwise <code>null</code> is 
       *   returned.
       * @exception DOMException
       *   WRONG_DOCUMENT_ERR: Raised if <code>newAttr</code> was created from a 
       *   different document than the one that created the element.
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly.
       *   <br>INUSE_ATTRIBUTE_ERR: Raised if <code>newAttr</code> is already an 
       *   attribute of another <code>Element</code> object. The DOM user must 
       *   explicitly clone <code>Attr</code> nodes to re-use them in other 
       *   elements.
       *   <br>NOT_SUPPORTED_ERR: Always thrown if the current document does not 
       *   support the <code>"XML"</code> feature, since namespaces were 
       *   defined by XML.
       * @since DOM Level 2
       */
      public Attr setAttributeNodeNS(Attr newAttr)
                                     throws DOMException;
  
      /**
       * Returns a <code>NodeList</code> of all the descendant 
       * <code>Elements</code> with a given local name and namespace URI in 
       * document order.
       * <br>Documents which do not support the "XML" feature will permit only 
       * the DOM Level 1 calls for creating/setting elements and attributes. 
       * Hence, if you specify a non-null namespace URI, these DOMs will never 
       * find a matching node.
       * @param namespaceURI The namespace URI of the elements to match on. The 
       *   special value "*" matches all namespaces.
       * @param localName The local name of the elements to match on. The 
       *   special value "*" matches all local names.
       * @return A new <code>NodeList</code> object containing all the matched 
       *   <code>Elements</code>.
       * @since DOM Level 2
       */
      public NodeList getElementsByTagNameNS(String namespaceURI, 
                                             String localName);
  
      /**
       * Returns <code>true</code> when an attribute with a given name is 
       * specified on this element or has a default value, <code>false</code> 
       * otherwise.
       * @param name The name of the attribute to look for.
       * @return <code>true</code> if an attribute with the given name is 
       *   specified on this element or has a default value, <code>false</code>
       *    otherwise.
       * @since DOM Level 2
       */
      public boolean hasAttribute(String name);
  
      /**
       * Returns <code>true</code> when an attribute with a given local name and 
       * namespace URI is specified on this element or has a default value, 
       * <code>false</code> otherwise.
       * <br>Documents which do not support the "XML" feature will permit only 
       * the DOM Level 1 calls for creating/setting elements and attributes. 
       * Hence, if you specify a non-null namespace URI, these DOMs will never 
       * find a matching node.
       * <br>Per , applications must use the value null as the namespaceURI 
       * parameter for methods if they wish to have no namespace.
       * @param namespaceURI The namespace URI of the attribute to look for.
       * @param localName The local name of the attribute to look for.
       * @return <code>true</code> if an attribute with the given local name 
       *   and namespace URI is specified or has a default value on this 
       *   element, <code>false</code> otherwise.
       * @since DOM Level 2
       */
      public boolean hasAttributeNS(String namespaceURI, 
                                    String localName);
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/Entity.java
  
  Index: Entity.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * This interface represents an entity, either parsed or unparsed, in an XML 
   * document. Note that this models the entity itself not the entity 
   * declaration. <code>Entity</code> declaration modeling has been left for a 
   * later Level of the DOM specification.
   * <p>The <code>nodeName</code> attribute that is inherited from 
   * <code>Node</code> contains the name of the entity.
   * <p>An XML processor may choose to completely expand entities before the 
   * structure model is passed to the DOM; in this case there will be no 
   * <code>EntityReference</code> nodes in the document tree.
   * <p>XML does not mandate that a non-validating XML processor read and 
   * process entity declarations made in the external subset or declared in 
   * external parameter entities. This means that parsed entities declared in 
   * the external subset need not be expanded by some classes of applications, 
   * and that the replacement text of the entity may not be available. When 
   * the replacement text is available, the corresponding <code>Entity</code> 
   * node's child list represents the structure of that replacement value. 
   * Otherwise, the child list is empty.
   * <p>The DOM Level 2 does not support editing <code>Entity</code> nodes; if a 
   * user wants to make changes to the contents of an <code>Entity</code>, 
   * every related <code>EntityReference</code> node has to be replaced in the 
   * structure model by a clone of the <code>Entity</code>'s contents, and 
   * then the desired changes must be made to each of those clones instead. 
   * <code>Entity</code> nodes and all their descendants are readonly.
   * <p>An <code>Entity</code> node does not have any parent.If the entity 
   * contains an unbound namespace prefix, the <code>namespaceURI</code> of 
   * the corresponding node in the <code>Entity</code> node subtree is 
   * <code>null</code>. The same is true for <code>EntityReference</code> 
   * nodes that refer to this entity, when they are created using the 
   * <code>createEntityReference</code> method of the <code>Document</code> 
   * interface. The DOM Level 2 does not support any mechanism to resolve 
   * namespace prefixes. The properties [notation name] and [notation] defined 
   * in  are not accessible from DOM Level 3 Core. However,  does provide a 
   * way to access them. 
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface Entity extends Node {
      /**
       * The public identifier associated with the entity if specified, and 
       * <code>null</code> otherwise.
       * <br> This attribute represents the property [public identifier] defined 
       * by the Unparsed Entity Information Item in . 
       */
      public String getPublicId();
  
      /**
       * The system identifier associated with the entity if specified, and 
       * <code>null</code> otherwise. This may be an absolute URI or not.
       * <br> This attribute represents the property [system identifier] defined 
       * by the Unparsed Entity Information Item in . 
       */
      public String getSystemId();
  
      /**
       * For unparsed entities, the name of the notation for the entity. For 
       * parsed entities, this is <code>null</code>.
       */
      public String getNotationName();
  
      /**
       * An attribute specifying the actual encoding of this entity, when it is 
       * an external parsed entity. This is <code>null</code> otherwise.
       * @since DOM Level 3
       */
      public String getActualEncoding();
      /**
       * An attribute specifying the actual encoding of this entity, when it is 
       * an external parsed entity. This is <code>null</code> otherwise.
       * @since DOM Level 3
       */
      public void setActualEncoding(String actualEncoding);
  
      /**
       * An attribute specifying, as part of the text declaration, the encoding 
       * of this entity, when it is an external parsed entity. This is 
       * <code>null</code> otherwise.
       * @since DOM Level 3
       */
      public String getEncoding();
      /**
       * An attribute specifying, as part of the text declaration, the encoding 
       * of this entity, when it is an external parsed entity. This is 
       * <code>null</code> otherwise.
       * @since DOM Level 3
       */
      public void setEncoding(String encoding);
  
      /**
       * An attribute specifying, as part of the text declaration, the version 
       * number of this entity, when it is an external parsed entity. This is 
       * <code>null</code> otherwise.
       * @since DOM Level 3
       */
      public String getVersion();
      /**
       * An attribute specifying, as part of the text declaration, the version 
       * number of this entity, when it is an external parsed entity. This is 
       * <code>null</code> otherwise.
       * @since DOM Level 3
       */
      public void setVersion(String version);
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/EntityReference.java
  
  Index: EntityReference.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * <code>EntityReference</code> objects may be inserted into the structure 
   * model when an entity reference is in the source document, or when the 
   * user wishes to insert an entity reference. Note that character references 
   * and references to predefined entities are considered to be expanded by 
   * the HTML or XML processor so that characters are represented by their 
   * Unicode equivalent rather than by an entity reference. Moreover, the XML 
   * processor may completely expand references to entities while building the 
   * structure model, instead of providing <code>EntityReference</code> 
   * objects. If it does provide such objects, then for a given 
   * <code>EntityReference</code> node, it may be that there is no 
   * <code>Entity</code> node representing the referenced entity. If such an 
   * <code>Entity</code> exists, then the subtree of the 
   * <code>EntityReference</code> node is in general a copy of the 
   * <code>Entity</code> node subtree. However, this may not be true when an 
   * entity contains an unbound namespace prefix. In such a case, because the 
   * namespace prefix resolution depends on where the entity reference is, the 
   * descendants of the <code>EntityReference</code> node may be bound to 
   * different namespace URIs.
   * <p>As for <code>Entity</code> nodes, <code>EntityReference</code> nodes and 
   * all their descendants are readonly. The properties [system identifier] 
   * and [public identifier] defined by the Unexpanded Entity Reference 
   * Information Item in  are accessible through the <code>Entity</code> 
   * interface. The property [all declarations processed] is not accessible 
   * through the DOM API. 
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface EntityReference extends Node {
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/NamedNodeMap.java
  
  Index: NamedNodeMap.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * Objects implementing the <code>NamedNodeMap</code> interface are used to 
   * represent collections of nodes that can be accessed by name. Note that 
   * <code>NamedNodeMap</code> does not inherit from <code>NodeList</code>; 
   * <code>NamedNodeMaps</code> are not maintained in any particular order. 
   * Objects contained in an object implementing <code>NamedNodeMap</code> may 
   * also be accessed by an ordinal index, but this is simply to allow 
   * convenient enumeration of the contents of a <code>NamedNodeMap</code>, 
   * and does not imply that the DOM specifies an order to these Nodes. 
   * <p><code>NamedNodeMap</code> objects in the DOM are live.
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface NamedNodeMap {
      /**
       * Retrieves a node specified by name.
       * @param name The <code>nodeName</code> of a node to retrieve.
       * @return A <code>Node</code> (of any type) with the specified 
       *   <code>nodeName</code>, or <code>null</code> if it does not identify 
       *   any node in this map.
       */
      public Node getNamedItem(String name);
  
      /**
       * Adds a node using its <code>nodeName</code> attribute. If a node with 
       * that name is already present in this map, it is replaced by the new 
       * one. Replacing a node by itself has no effect.
       * <br>As the <code>nodeName</code> attribute is used to derive the name 
       * which the node must be stored under, multiple nodes of certain types 
       * (those that have a "special" string value) cannot be stored as the 
       * names would clash. This is seen as preferable to allowing nodes to be 
       * aliased.
       * @param arg A node to store in this map. The node will later be 
       *   accessible using the value of its <code>nodeName</code> attribute.
       * @return If the new <code>Node</code> replaces an existing node the 
       *   replaced <code>Node</code> is returned, otherwise <code>null</code> 
       *   is returned.
       * @exception DOMException
       *   WRONG_DOCUMENT_ERR: Raised if <code>arg</code> was created from a 
       *   different document than the one that created this map.
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this map is readonly.
       *   <br>INUSE_ATTRIBUTE_ERR: Raised if <code>arg</code> is an 
       *   <code>Attr</code> that is already an attribute of another 
       *   <code>Element</code> object. The DOM user must explicitly clone 
       *   <code>Attr</code> nodes to re-use them in other elements.
       *   <br>HIERARCHY_REQUEST_ERR: Raised if an attempt is made to add a node 
       *   doesn't belong in this NamedNodeMap. Examples would include trying 
       *   to insert something other than an Attr node into an Element's map 
       *   of attributes, or a non-Entity node into the DocumentType's map of 
       *   Entities.
       */
      public Node setNamedItem(Node arg)
                               throws DOMException;
  
      /**
       * Removes a node specified by name. When this map contains the attributes 
       * attached to an element, if the removed attribute is known to have a 
       * default value, an attribute immediately appears containing the 
       * default value as well as the corresponding namespace URI, local name, 
       * and prefix when applicable.
       * @param name The <code>nodeName</code> of the node to remove.
       * @return The node removed from this map if a node with such a name 
       *   exists.
       * @exception DOMException
       *   NOT_FOUND_ERR: Raised if there is no node named <code>name</code> in 
       *   this map.
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this map is readonly.
       */
      public Node removeNamedItem(String name)
                                  throws DOMException;
  
      /**
       * Returns the <code>index</code>th item in the map. If <code>index</code> 
       * is greater than or equal to the number of nodes in this map, this 
       * returns <code>null</code>.
       * @param index Index into this map.
       * @return The node at the <code>index</code>th position in the map, or 
       *   <code>null</code> if that is not a valid index.
       */
      public Node item(int index);
  
      /**
       * The number of nodes in this map. The range of valid child node indices 
       * is <code>0</code> to <code>length-1</code> inclusive.
       */
      public int getLength();
  
      /**
       * Retrieves a node specified by local name and namespace URI.
       * <br>Documents which do not support the "XML" feature will permit only 
       * the DOM Level 1 calls for creating/setting elements and attributes. 
       * Hence, if you specify a non-null namespace URI, these DOMs will never 
       * find a matching node.
       * <br>Per , applications must use the value null as the namespaceURI 
       * parameter for methods if they wish to have no namespace.
       * @param namespaceURI The namespace URI of the node to retrieve.
       * @param localName The local name of the node to retrieve.
       * @return A <code>Node</code> (of any type) with the specified local 
       *   name and namespace URI, or <code>null</code> if they do not 
       *   identify any node in this map.
       * @since DOM Level 2
       */
      public Node getNamedItemNS(String namespaceURI, 
                                 String localName);
  
      /**
       * Adds a node using its <code>namespaceURI</code> and 
       * <code>localName</code>. If a node with that namespace URI and that 
       * local name is already present in this map, it is replaced by the new 
       * one. Replacing a node by itself has no effect.
       * <br>Per , applications must use the value null as the namespaceURI 
       * parameter for methods if they wish to have no namespace.
       * @param arg A node to store in this map. The node will later be 
       *   accessible using the value of its <code>namespaceURI</code> and 
       *   <code>localName</code> attributes.
       * @return If the new <code>Node</code> replaces an existing node the 
       *   replaced <code>Node</code> is returned, otherwise <code>null</code> 
       *   is returned.
       * @exception DOMException
       *   WRONG_DOCUMENT_ERR: Raised if <code>arg</code> was created from a 
       *   different document than the one that created this map.
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this map is readonly.
       *   <br>INUSE_ATTRIBUTE_ERR: Raised if <code>arg</code> is an 
       *   <code>Attr</code> that is already an attribute of another 
       *   <code>Element</code> object. The DOM user must explicitly clone 
       *   <code>Attr</code> nodes to re-use them in other elements.
       *   <br>HIERARCHY_REQUEST_ERR: Raised if an attempt is made to add a node 
       *   doesn't belong in this NamedNodeMap. Examples would include trying 
       *   to insert something other than an Attr node into an Element's map 
       *   of attributes, or a non-Entity node into the DocumentType's map of 
       *   Entities.
       *   <br>NOT_SUPPORTED_ERR: Always thrown if the current document does not 
       *   support the <code>"XML"</code> feature, since namespaces were 
       *   defined by XML.
       * @since DOM Level 2
       */
      public Node setNamedItemNS(Node arg)
                                 throws DOMException;
  
      /**
       * Removes a node specified by local name and namespace URI. A removed 
       * attribute may be known to have a default value when this map contains 
       * the attributes attached to an element, as returned by the attributes 
       * attribute of the <code>Node</code> interface. If so, an attribute 
       * immediately appears containing the default value as well as the 
       * corresponding namespace URI, local name, and prefix when applicable.
       * <br>Documents which do not support the "XML" feature will permit only 
       * the DOM Level 1 calls for creating/setting elements and attributes. 
       * Hence, if you specify a non-null namespace URI, these DOMs will never 
       * find a matching node.
       * <br>Per , applications must use the value null as the namespaceURI 
       * parameter for methods if they wish to have no namespace.
       * @param namespaceURI The namespace URI of the node to remove.
       * @param localName The local name of the node to remove.
       * @return The node removed from this map if a node with such a local 
       *   name and namespace URI exists.
       * @exception DOMException
       *   NOT_FOUND_ERR: Raised if there is no node with the specified 
       *   <code>namespaceURI</code> and <code>localName</code> in this map.
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this map is readonly.
       * @since DOM Level 2
       */
      public Node removeNamedItemNS(String namespaceURI, 
                                    String localName)
                                    throws DOMException;
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/Node.java
  
  Index: Node.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * The <code>Node</code> interface is the primary datatype for the entire 
   * Document Object Model. It represents a single node in the document tree. 
   * While all objects implementing the <code>Node</code> interface expose 
   * methods for dealing with children, not all objects implementing the 
   * <code>Node</code> interface may have children. For example, 
   * <code>Text</code> nodes may not have children, and adding children to 
   * such nodes results in a <code>DOMException</code> being raised.
   * <p>The attributes <code>nodeName</code>, <code>nodeValue</code> and 
   * <code>attributes</code> are included as a mechanism to get at node 
   * information without casting down to the specific derived interface. In 
   * cases where there is no obvious mapping of these attributes for a 
   * specific <code>nodeType</code> (e.g., <code>nodeValue</code> for an 
   * <code>Element</code> or <code>attributes</code> for a <code>Comment</code>
   * ), this returns <code>null</code>. Note that the specialized interfaces 
   * may contain additional and more convenient mechanisms to get and set the 
   * relevant information.
   * <p>The values of <code>nodeName</code>, 
   * <code>nodeValue</code>, and <code>attributes</code> vary according to the 
   * node type as follows: 
   * <table border='1'>
   * <tr>
   * <th>Interface</th>
   * <th>nodeName</th>
   * <th>nodeValue</th>
   * <th>attributes</th>
   * </tr>
   * <tr>
   * <td valign='top' rowspan='1' colspan='1'>Attr</td>
   * <td valign='top' rowspan='1' colspan='1'>name of 
   * attribute</td>
   * <td valign='top' rowspan='1' colspan='1'>value of attribute</td>
   * <td valign='top' rowspan='1' colspan='1'>null</td>
   * </tr>
   * <tr>
   * <td valign='top' rowspan='1' colspan='1'>CDATASection</td>
   * <td valign='top' rowspan='1' colspan='1'><code>"#cdata-section"</code></td>
   * <td valign='top' rowspan='1' colspan='1'>
   * content of the CDATA Section</td>
   * <td valign='top' rowspan='1' colspan='1'>null</td>
   * </tr>
   * <tr>
   * <td valign='top' rowspan='1' colspan='1'>Comment</td>
   * <td valign='top' rowspan='1' colspan='1'><code>"#comment"</code></td>
   * <td valign='top' rowspan='1' colspan='1'>content of 
   * the comment</td>
   * <td valign='top' rowspan='1' colspan='1'>null</td>
   * </tr>
   * <tr>
   * <td valign='top' rowspan='1' colspan='1'>Document</td>
   * <td valign='top' rowspan='1' colspan='1'><code>"#document"</code></td>
   * <td valign='top' rowspan='1' colspan='1'>null</td>
   * <td valign='top' rowspan='1' colspan='1'>null</td>
   * </tr>
   * <tr>
   * <td valign='top' rowspan='1' colspan='1'>DocumentFragment</td>
   * <td valign='top' rowspan='1' colspan='1'>
   * <code>"#document-fragment"</code></td>
   * <td valign='top' rowspan='1' colspan='1'>null</td>
   * <td valign='top' rowspan='1' colspan='1'>null</td>
   * </tr>
   * <tr>
   * <td valign='top' rowspan='1' colspan='1'>DocumentType</td>
   * <td valign='top' rowspan='1' colspan='1'>document type name</td>
   * <td valign='top' rowspan='1' colspan='1'>
   * null</td>
   * <td valign='top' rowspan='1' colspan='1'>null</td>
   * </tr>
   * <tr>
   * <td valign='top' rowspan='1' colspan='1'>Element</td>
   * <td valign='top' rowspan='1' colspan='1'>tag name</td>
   * <td valign='top' rowspan='1' colspan='1'>null</td>
   * <td valign='top' rowspan='1' colspan='1'>NamedNodeMap</td>
   * </tr>
   * <tr>
   * <td valign='top' rowspan='1' colspan='1'>Entity</td>
   * <td valign='top' rowspan='1' colspan='1'>entity name</td>
   * <td valign='top' rowspan='1' colspan='1'>null</td>
   * <td valign='top' rowspan='1' colspan='1'>null</td>
   * </tr>
   * <tr>
   * <td valign='top' rowspan='1' colspan='1'>
   * EntityReference</td>
   * <td valign='top' rowspan='1' colspan='1'>name of entity referenced</td>
   * <td valign='top' rowspan='1' colspan='1'>null</td>
   * <td valign='top' rowspan='1' colspan='1'>null</td>
   * </tr>
   * <tr>
   * <td valign='top' rowspan='1' colspan='1'>Notation</td>
   * <td valign='top' rowspan='1' colspan='1'>notation name</td>
   * <td valign='top' rowspan='1' colspan='1'>null</td>
   * <td valign='top' rowspan='1' colspan='1'>
   * null</td>
   * </tr>
   * <tr>
   * <td valign='top' rowspan='1' colspan='1'>ProcessingInstruction</td>
   * <td valign='top' rowspan='1' colspan='1'>target</td>
   * <td valign='top' rowspan='1' colspan='1'>entire content excluding the target</td>
   * <td valign='top' rowspan='1' colspan='1'>null</td>
   * </tr>
   * <tr>
   * <td valign='top' rowspan='1' colspan='1'>Text</td>
   * <td valign='top' rowspan='1' colspan='1'>
   * <code>"#text"</code></td>
   * <td valign='top' rowspan='1' colspan='1'>content of the text node</td>
   * <td valign='top' rowspan='1' colspan='1'>null</td>
   * </tr>
   * </table> 
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface Node {
      // NodeType
      /**
       * The node is an <code>Element</code>.
       */
      public static final short ELEMENT_NODE              = 1;
      /**
       * The node is an <code>Attr</code>.
       */
      public static final short ATTRIBUTE_NODE            = 2;
      /**
       * The node is a <code>Text</code> node.
       */
      public static final short TEXT_NODE                 = 3;
      /**
       * The node is a <code>CDATASection</code>.
       */
      public static final short CDATA_SECTION_NODE        = 4;
      /**
       * The node is an <code>EntityReference</code>.
       */
      public static final short ENTITY_REFERENCE_NODE     = 5;
      /**
       * The node is an <code>Entity</code>.
       */
      public static final short ENTITY_NODE               = 6;
      /**
       * The node is a <code>ProcessingInstruction</code>.
       */
      public static final short PROCESSING_INSTRUCTION_NODE = 7;
      /**
       * The node is a <code>Comment</code>.
       */
      public static final short COMMENT_NODE              = 8;
      /**
       * The node is a <code>Document</code>.
       */
      public static final short DOCUMENT_NODE             = 9;
      /**
       * The node is a <code>DocumentType</code>.
       */
      public static final short DOCUMENT_TYPE_NODE        = 10;
      /**
       * The node is a <code>DocumentFragment</code>.
       */
      public static final short DOCUMENT_FRAGMENT_NODE    = 11;
      /**
       * The node is a <code>Notation</code>.
       */
      public static final short NOTATION_NODE             = 12;
  
      /**
       * The name of this node, depending on its type; see the table above.
       */
      public String getNodeName();
  
      /**
       * The value of this node, depending on its type; see the table above. 
       * When it is defined to be <code>null</code>, setting it has no effect.
       * @exception DOMException
       *   NO_MODIFICATION_ALLOWED_ERR: Raised when the node is readonly.
       * @exception DOMException
       *   DOMSTRING_SIZE_ERR: Raised when it would return more characters than 
       *   fit in a <code>DOMString</code> variable on the implementation 
       *   platform.
       */
      public String getNodeValue()
                                throws DOMException;
      /**
       * The value of this node, depending on its type; see the table above. 
       * When it is defined to be <code>null</code>, setting it has no effect.
       * @exception DOMException
       *   NO_MODIFICATION_ALLOWED_ERR: Raised when the node is readonly.
       * @exception DOMException
       *   DOMSTRING_SIZE_ERR: Raised when it would return more characters than 
       *   fit in a <code>DOMString</code> variable on the implementation 
       *   platform.
       */
      public void setNodeValue(String nodeValue)
                                throws DOMException;
  
      /**
       * A code representing the type of the underlying object, as defined above.
       */
      public short getNodeType();
  
      /**
       * The parent of this node. All nodes, except <code>Attr</code>, 
       * <code>Document</code>, <code>DocumentFragment</code>, 
       * <code>Entity</code>, and <code>Notation</code> may have a parent. 
       * However, if a node has just been created and not yet added to the 
       * tree, or if it has been removed from the tree, this is 
       * <code>null</code>. 
       * <br> When the node is an <code>Element</code>, a 
       * <code>ProcessingInstruction</code>, an <code>EntityReference</code>, 
       * a <code>CharacterData</code>, a <code>Comment</code>, or a 
       * <code>DocumentType</code>, this attribute represents the properties 
       * [parent] defined in . 
       */
      public Node getParentNode();
  
      /**
       * A <code>NodeList</code> that contains all children of this node. If 
       * there are no children, this is a <code>NodeList</code> containing no 
       * nodes.
       * <br> When the node is a <code>Document</code>, or an 
       * <code>Element</code>, and if the <code>NodeList</code> does not 
       * contain <code>EntityReference</code> or <code>CDATASection</code> 
       * nodes, this attribute represents the properties [children] defined in 
       * . 
       */
      public NodeList getChildNodes();
  
      /**
       * The first child of this node. If there is no such node, this returns 
       * <code>null</code>.
       */
      public Node getFirstChild();
  
      /**
       * The last child of this node. If there is no such node, this returns 
       * <code>null</code>.
       */
      public Node getLastChild();
  
      /**
       * The node immediately preceding this node. If there is no such node, 
       * this returns <code>null</code>.
       */
      public Node getPreviousSibling();
  
      /**
       * The node immediately following this node. If there is no such node, 
       * this returns <code>null</code>.
       */
      public Node getNextSibling();
  
      /**
       * A <code>NamedNodeMap</code> containing the attributes of this node (if 
       * it is an <code>Element</code>) or <code>null</code> otherwise.
       * <br> If no namespace declaration appear in the attributes, this 
       * attribute represents the property [attributes] defined in . If 
       * namespace declarations appear in the attributes, this attribute 
       * combines the properties [attributes] and [namespace attributes] 
       * defined in . 
       */
      public NamedNodeMap getAttributes();
  
      /**
       * The <code>Document</code> object associated with this node. This is 
       * also the <code>Document</code> object used to create new nodes. When 
       * this node is a <code>Document</code> or a <code>DocumentType</code> 
       * which is not used with any <code>Document</code> yet, this is 
       * <code>null</code>.
       * @version DOM Level 2
       */
      public Document getOwnerDocument();
  
      /**
       * Inserts the node <code>newChild</code> before the existing child node 
       * <code>refChild</code>. If <code>refChild</code> is <code>null</code>, 
       * insert <code>newChild</code> at the end of the list of children.
       * <br>If <code>newChild</code> is a <code>DocumentFragment</code> object, 
       * all of its children are inserted, in the same order, before 
       * <code>refChild</code>. If the <code>newChild</code> is already in the 
       * tree, it is first removed.
       * @param newChild The node to insert.
       * @param refChild The reference node, i.e., the node before which the 
       *   new node must be inserted.
       * @return The node being inserted.
       * @exception DOMException
       *   HIERARCHY_REQUEST_ERR: Raised if this node is of a type that does not 
       *   allow children of the type of the <code>newChild</code> node, or if 
       *   the node to insert is one of this node's ancestors or this node 
       *   itself, or if this node if of type <code>Document</code> and the 
       *   DOM application attempts to insert a second 
       *   <code>DocumentType</code> or <code>Element</code> node.
       *   <br>WRONG_DOCUMENT_ERR: Raised if <code>newChild</code> was created 
       *   from a different document than the one that created this node.
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly or 
       *   if the parent of the node being inserted is readonly.
       *   <br>NOT_FOUND_ERR: Raised if <code>refChild</code> is not a child of 
       *   this node.
       *   <br>NOT_SUPPORTED_ERR: if this node if of type <code>Document</code>, 
       *   this exception might be raised if the DOM implementation doesn't 
       *   support the insertion of a <code>DocumentType</code> or 
       *   <code>Element</code> node.
       * @version DOM Level 3
       */
      public Node insertBefore(Node newChild, 
                               Node refChild)
                               throws DOMException;
  
      /**
       * Replaces the child node <code>oldChild</code> with <code>newChild</code>
       *  in the list of children, and returns the <code>oldChild</code> node.
       * <br>If <code>newChild</code> is a <code>DocumentFragment</code> object, 
       * <code>oldChild</code> is replaced by all of the 
       * <code>DocumentFragment</code> children, which are inserted in the 
       * same order. If the <code>newChild</code> is already in the tree, it 
       * is first removed.
       * @param newChild The new node to put in the child list.
       * @param oldChild The node being replaced in the list.
       * @return The node replaced.
       * @exception DOMException
       *   HIERARCHY_REQUEST_ERR: Raised if this node is of a type that does not 
       *   allow children of the type of the <code>newChild</code> node, or if 
       *   the node to put in is one of this node's ancestors or this node 
       *   itself.
       *   <br>WRONG_DOCUMENT_ERR: Raised if <code>newChild</code> was created 
       *   from a different document than the one that created this node.
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this node or the parent of 
       *   the new node is readonly.
       *   <br>NOT_FOUND_ERR: Raised if <code>oldChild</code> is not a child of 
       *   this node.
       *   <br>NOT_SUPPORTED_ERR: if this node if of type <code>Document</code>, 
       *   this exception might be raised if the DOM implementation doesn't 
       *   support the replacement of the <code>DocumentType</code> child or 
       *   <code>Element</code> child.
       * @version DOM Level 3
       */
      public Node replaceChild(Node newChild, 
                               Node oldChild)
                               throws DOMException;
  
      /**
       * Removes the child node indicated by <code>oldChild</code> from the list 
       * of children, and returns it.
       * @param oldChild The node being removed.
       * @return The node removed.
       * @exception DOMException
       *   NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly.
       *   <br>NOT_FOUND_ERR: Raised if <code>oldChild</code> is not a child of 
       *   this node.
       *   <br>NOT_SUPPORTED_ERR: if this node if of type <code>Document</code>, 
       *   this exception might be raised if the DOM implementation doesn't 
       *   support the removal of the <code>DocumentType</code> child or the 
       *   <code>Element</code> child.
       * @version DOM Level 3
       */
      public Node removeChild(Node oldChild)
                              throws DOMException;
  
      /**
       * Adds the node <code>newChild</code> to the end of the list of children 
       * of this node. If the <code>newChild</code> is already in the tree, it 
       * is first removed.
       * @param newChild The node to add.If it is a 
       *   <code>DocumentFragment</code> object, the entire contents of the 
       *   document fragment are moved into the child list of this node
       * @return The node added.
       * @exception DOMException
       *   HIERARCHY_REQUEST_ERR: Raised if this node is of a type that does not 
       *   allow children of the type of the <code>newChild</code> node, or if 
       *   the node to append is one of this node's ancestors or this node 
       *   itself.
       *   <br>WRONG_DOCUMENT_ERR: Raised if <code>newChild</code> was created 
       *   from a different document than the one that created this node.
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly or 
       *   if the previous parent of the node being inserted is readonly.
       */
      public Node appendChild(Node newChild)
                              throws DOMException;
  
      /**
       * Returns whether this node has any children.
       * @return <code>true</code> if this node has any children, 
       *   <code>false</code> otherwise.
       */
      public boolean hasChildNodes();
  
      /**
       * Returns a duplicate of this node, i.e., serves as a generic copy 
       * constructor for nodes. The duplicate node has no parent; (
       * <code>parentNode</code> is <code>null</code>.) and no user data. User 
       * data associated to the imported node is not carried over. However, if 
       * any <code>UserDataHandlers</code> has been specified along with the 
       * associated data these handlers will be called with the appropriate 
       * parameters before this method returns.
       * <br>Cloning an <code>Element</code> copies all attributes and their 
       * values, including those generated by the XML processor to represent 
       * defaulted attributes, but this method does not copy any children it 
       * contains unless it is a deep clone. This includes text contained in 
       * an the <code>Element</code> since the text is contained in a child 
       * <code>Text</code> node. Cloning an <code>Attribute</code> directly, 
       * as opposed to be cloned as part of an <code>Element</code> cloning 
       * operation, returns a specified attribute (<code>specified</code> is 
       * <code>true</code>). Cloning an <code>Attribute</code> always clones 
       * its children, since they represent its value, no matter whether this 
       * is a deep clone or not. Cloning an <code>EntityReference</code> 
       * automatically constructs its subtree if a corresponding 
       * <code>Entity</code> is available, no matter whether this is a deep 
       * clone or not. Cloning any other type of node simply returns a copy of 
       * this node.
       * <br>Note that cloning an immutable subtree results in a mutable copy, 
       * but the children of an <code>EntityReference</code> clone are readonly
       * . In addition, clones of unspecified <code>Attr</code> nodes are 
       * specified. And, cloning <code>Document</code>, 
       * <code>DocumentType</code>, <code>Entity</code>, and 
       * <code>Notation</code> nodes is implementation dependent.
       * @param deep If <code>true</code>, recursively clone the subtree under 
       *   the specified node; if <code>false</code>, clone only the node 
       *   itself (and its attributes, if it is an <code>Element</code>).
       * @return The duplicate node.
       */
      public Node cloneNode(boolean deep);
  
      /**
       * Puts all <code>Text</code> nodes in the full depth of the sub-tree 
       * underneath this <code>Node</code>, including attribute nodes, into a 
       * "normal" form where only structure (e.g., elements, comments, 
       * processing instructions, CDATA sections, and entity references) 
       * separates <code>Text</code> nodes, i.e., there are neither adjacent 
       * <code>Text</code> nodes nor empty <code>Text</code> nodes. This can 
       * be used to ensure that the DOM view of a document is the same as if 
       * it were saved and re-loaded, and is useful when operations (such as 
       * XPointer  lookups) that depend on a particular document tree 
       * structure are to be used.In cases where the document contains 
       * <code>CDATASections</code>, the normalize operation alone may not be 
       * sufficient, since XPointers do not differentiate between 
       * <code>Text</code> nodes and <code>CDATASection</code> nodes.
       * @version DOM Level 2
       */
      public void normalize();
  
      /**
       * Tests whether the DOM implementation implements a specific feature and 
       * that feature is supported by this node.
       * @param feature The name of the feature to test. This is the same name 
       *   which can be passed to the method <code>hasFeature</code> on 
       *   <code>DOMImplementation</code>.
       * @param version This is the version number of the feature to test. In 
       *   Level 2, version 1, this is the string "2.0". If the version is not 
       *   specified, supporting any version of the feature will cause the 
       *   method to return <code>true</code>.
       * @return Returns <code>true</code> if the specified feature is 
       *   supported on this node, <code>false</code> otherwise.
       * @since DOM Level 2
       */
      public boolean isSupported(String feature, 
                                 String version);
  
      /**
       * The namespace URI of this node, or <code>null</code> if it is 
       * unspecified.
       * <br> When the node is <code>Element</code>, or <code>Attr</code>, this 
       * attribute represents the properties [namespace name] defined in . 
       * <br>This is not a computed value that is the result of a namespace 
       * lookup based on an examination of the namespace declarations in 
       * scope. It is merely the namespace URI given at creation time.
       * <br>For nodes of any type other than <code>ELEMENT_NODE</code> and 
       * <code>ATTRIBUTE_NODE</code> and nodes created with a DOM Level 1 
       * method, such as <code>createElement</code> from the 
       * <code>Document</code> interface, this is always <code>null</code>.Per 
       * the Namespaces in XML Specification  an attribute does not inherit 
       * its namespace from the element it is attached to. If an attribute is 
       * not explicitly given a namespace, it simply has no namespace.
       * @since DOM Level 2
       */
      public String getNamespaceURI();
  
      /**
       * The namespace prefix of this node, or <code>null</code> if it is 
       * unspecified.
       * <br> When the node is <code>Element</code>, or <code>Attr</code>, this 
       * attribute represents the properties [prefix] defined in . 
       * <br>Note that setting this attribute, when permitted, changes the 
       * <code>nodeName</code> attribute, which holds the qualified name, as 
       * well as the <code>tagName</code> and <code>name</code> attributes of 
       * the <code>Element</code> and <code>Attr</code> interfaces, when 
       * applicable.
       * <br>Note also that changing the prefix of an attribute that is known to 
       * have a default value, does not make a new attribute with the default 
       * value and the original prefix appear, since the 
       * <code>namespaceURI</code> and <code>localName</code> do not change.
       * <br>For nodes of any type other than <code>ELEMENT_NODE</code> and 
       * <code>ATTRIBUTE_NODE</code> and nodes created with a DOM Level 1 
       * method, such as <code>createElement</code> from the 
       * <code>Document</code> interface, this is always <code>null</code>.
       * @exception DOMException
       *   INVALID_CHARACTER_ERR: Raised if the specified prefix contains an 
       *   illegal character, per the XML 1.0 specification .
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly.
       *   <br>NAMESPACE_ERR: Raised if the specified <code>prefix</code> is 
       *   malformed per the Namespaces in XML specification, if the 
       *   <code>namespaceURI</code> of this node is <code>null</code>, if the 
       *   specified prefix is "xml" and the <code>namespaceURI</code> of this 
       *   node is different from "http://www.w3.org/XML/1998/namespace", if 
       *   this node is an attribute and the specified prefix is "xmlns" and 
       *   the <code>namespaceURI</code> of this node is different from "
       *   http://www.w3.org/2000/xmlns/", or if this node is an attribute and 
       *   the <code>qualifiedName</code> of this node is "xmlns" .
       * @since DOM Level 2
       */
      public String getPrefix();
      /**
       * The namespace prefix of this node, or <code>null</code> if it is 
       * unspecified.
       * <br> When the node is <code>Element</code>, or <code>Attr</code>, this 
       * attribute represents the properties [prefix] defined in . 
       * <br>Note that setting this attribute, when permitted, changes the 
       * <code>nodeName</code> attribute, which holds the qualified name, as 
       * well as the <code>tagName</code> and <code>name</code> attributes of 
       * the <code>Element</code> and <code>Attr</code> interfaces, when 
       * applicable.
       * <br>Note also that changing the prefix of an attribute that is known to 
       * have a default value, does not make a new attribute with the default 
       * value and the original prefix appear, since the 
       * <code>namespaceURI</code> and <code>localName</code> do not change.
       * <br>For nodes of any type other than <code>ELEMENT_NODE</code> and 
       * <code>ATTRIBUTE_NODE</code> and nodes created with a DOM Level 1 
       * method, such as <code>createElement</code> from the 
       * <code>Document</code> interface, this is always <code>null</code>.
       * @exception DOMException
       *   INVALID_CHARACTER_ERR: Raised if the specified prefix contains an 
       *   illegal character, per the XML 1.0 specification .
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly.
       *   <br>NAMESPACE_ERR: Raised if the specified <code>prefix</code> is 
       *   malformed per the Namespaces in XML specification, if the 
       *   <code>namespaceURI</code> of this node is <code>null</code>, if the 
       *   specified prefix is "xml" and the <code>namespaceURI</code> of this 
       *   node is different from "http://www.w3.org/XML/1998/namespace", if 
       *   this node is an attribute and the specified prefix is "xmlns" and 
       *   the <code>namespaceURI</code> of this node is different from "
       *   http://www.w3.org/2000/xmlns/", or if this node is an attribute and 
       *   the <code>qualifiedName</code> of this node is "xmlns" .
       * @since DOM Level 2
       */
      public void setPrefix(String prefix)
                                 throws DOMException;
  
      /**
       * Returns the local part of the qualified name of this node.
       * <br> When the node is <code>Element</code>, or <code>Attr</code>, this 
       * attribute represents the properties [local name] defined in . 
       * <br>For nodes of any type other than <code>ELEMENT_NODE</code> and 
       * <code>ATTRIBUTE_NODE</code> and nodes created with a DOM Level 1 
       * method, such as <code>createElement</code> from the 
       * <code>Document</code> interface, this is always <code>null</code>.
       * @since DOM Level 2
       */
      public String getLocalName();
  
      /**
       * Returns whether this node (if it is an element) has any attributes.
       * @return <code>true</code> if this node has any attributes, 
       *   <code>false</code> otherwise.
       * @since DOM Level 2
       */
      public boolean hasAttributes();
  
      /**
       * The absolute base URI of this node or <code>null</code> if undefined. 
       * This value is computed according to . However, when the 
       * <code>Document</code> supports the feature "HTML" , the base URI is 
       * computed using first the value of the href attribute of the HTML BASE 
       * element if any, and the value of the <code>documentURI</code> 
       * attribute from the <code>Document</code> interface otherwise.
       * <br> When the node is an <code>Element</code>, a <code>Document</code> 
       * or a a <code>ProcessingInstruction</code>, this attribute represents 
       * the properties [base URI] defined in . When the node is a 
       * <code>Notation</code>, an <code>Entity</code>, or an 
       * <code>EntityReference</code>, this attribute represents the 
       * properties [declaration base URI] in the . How will this be affected 
       * by resolution of relative namespace URIs issue?It's not.Should this 
       * only be on Document, Element, ProcessingInstruction, Entity, and 
       * Notation nodes, according to the infoset? If not, what is it equal to 
       * on other nodes? Null? An empty string? I think it should be the 
       * parent's.No.Should this be read-only and computed or and actual 
       * read-write attribute?Read-only and computed (F2F 19 Jun 2000 and 
       * teleconference 30 May 2001).If the base HTML element is not yet 
       * attached to a document, does the insert change the Document.baseURI?
       * Yes. (F2F 26 Sep 2001)
       * @since DOM Level 3
       */
      public String getBaseURI();
  
      // TreePosition
      /**
       * The node precedes the reference node.
       */
      public static final short TREE_POSITION_PRECEDING   = 0x01;
      /**
       * The node follows the reference node.
       */
      public static final short TREE_POSITION_FOLLOWING   = 0x02;
      /**
       * The node is an ancestor of the reference node.
       */
      public static final short TREE_POSITION_ANCESTOR    = 0x04;
      /**
       * The node is a descendant of the reference node.
       */
      public static final short TREE_POSITION_DESCENDANT  = 0x08;
      /**
       * The two nodes have an equivalent position. This is the case of two 
       * attributes that have the same <code>ownerElement</code>, and two 
       * nodes that are the same.
       */
      public static final short TREE_POSITION_EQUIVALENT  = 0x10;
      /**
       * The two nodes are the same. Two nodes that are the same have an 
       * equivalent position, though the reverse may not be true.
       */
      public static final short TREE_POSITION_SAME_NODE   = 0x20;
      /**
       * The two nodes are disconnected, they do not have any common ancestor. 
       * This is the case of two nodes that are not in the same document.
       */
      public static final short TREE_POSITION_DISCONNECTED = 0x00;
  
      /**
       * Compares a node with this node with regard to their position in the 
       * tree and according to the document order. This order can be extended 
       * by module that define additional types of nodes.Should this method be 
       * optional?No.Need reference for namespace nodes.No, instead avoid 
       * referencing them directly.
       * @param other The node to compare against this node.
       * @return Returns how the given node is positioned relatively to this 
       *   node.
       * @since DOM Level 3
       */
      public short compareTreePosition(Node other);
  
      /**
       * This attribute returns the text content of this node and its 
       * descendants. When it is defined to be null, setting it has no effect. 
       * When set, any possible children this node may have are removed and 
       * replaced by a single <code>Text</code> node containing the string 
       * this attribute is set to. On getting, no serialization is performed, 
       * the returned string does not contain any markup. No whitespace 
       * normalization is performed, the returned string does not contain the 
       * element content whitespaces . Similarly, on setting, no parsing is 
       * performed either, the input string is taken as pure textual content.
       * <br>The string returned is made of the text content of this node 
       * depending on its type, as defined below: 
       * <table border='1'>
       * <tr>
       * <th>Node type</th>
       * <th>Content</th>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'>
       * ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, 
       * DOCUMENT_FRAGMENT_NODE</td>
       * <td valign='top' rowspan='1' colspan='1'>concatenation of the <code>textContent</code> 
       * attribute value of every child node, excluding COMMENT_NODE and 
       * PROCESSING_INSTRUCTION_NODE nodes</td>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'>ATTRIBUTE_NODE, TEXT_NODE, 
       * CDATA_SECTION_NODE, COMMENT_NODE, PROCESSING_INSTRUCTION_NODE</td>
       * <td valign='top' rowspan='1' colspan='1'>
       * <code>nodeValue</code></td>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'>DOCUMENT_NODE, DOCUMENT_TYPE_NODE, NOTATION_NODE</td>
       * <td valign='top' rowspan='1' colspan='1'>
       * null</td>
       * </tr>
       * </table> Should any whitespace normalization be performed? MS' text 
       * property doesn't but what about "ignorable whitespace"?Does not 
       * perform any whitespace normalization and ignores "ignorable 
       * whitespace".Should this be two methods instead?No. Keep it a read 
       * write attribute.What about the name? MS uses text and innerText. text 
       * conflicts with HTML DOM.Keep the current name, MS has a different 
       * name and different semantic.Should this be optional?No.Setting the 
       * text property on a Document, Document Type, or Notation node is an 
       * error for MS. How do we expose it? Exception? Which one?
       * (teleconference 23 May 2001) consistency with nodeValue. Remove 
       * Document from the list.
       * @exception DOMException
       *   NO_MODIFICATION_ALLOWED_ERR: Raised when the node is readonly.
       * @exception DOMException
       *   DOMSTRING_SIZE_ERR: Raised when it would return more characters than 
       *   fit in a <code>DOMString</code> variable on the implementation 
       *   platform.
       * @since DOM Level 3
       */
      public String getTextContent()
                                       throws DOMException;
      /**
       * This attribute returns the text content of this node and its 
       * descendants. When it is defined to be null, setting it has no effect. 
       * When set, any possible children this node may have are removed and 
       * replaced by a single <code>Text</code> node containing the string 
       * this attribute is set to. On getting, no serialization is performed, 
       * the returned string does not contain any markup. No whitespace 
       * normalization is performed, the returned string does not contain the 
       * element content whitespaces . Similarly, on setting, no parsing is 
       * performed either, the input string is taken as pure textual content.
       * <br>The string returned is made of the text content of this node 
       * depending on its type, as defined below: 
       * <table border='1'>
       * <tr>
       * <th>Node type</th>
       * <th>Content</th>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'>
       * ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, 
       * DOCUMENT_FRAGMENT_NODE</td>
       * <td valign='top' rowspan='1' colspan='1'>concatenation of the <code>textContent</code> 
       * attribute value of every child node, excluding COMMENT_NODE and 
       * PROCESSING_INSTRUCTION_NODE nodes</td>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'>ATTRIBUTE_NODE, TEXT_NODE, 
       * CDATA_SECTION_NODE, COMMENT_NODE, PROCESSING_INSTRUCTION_NODE</td>
       * <td valign='top' rowspan='1' colspan='1'>
       * <code>nodeValue</code></td>
       * </tr>
       * <tr>
       * <td valign='top' rowspan='1' colspan='1'>DOCUMENT_NODE, DOCUMENT_TYPE_NODE, NOTATION_NODE</td>
       * <td valign='top' rowspan='1' colspan='1'>
       * null</td>
       * </tr>
       * </table> Should any whitespace normalization be performed? MS' text 
       * property doesn't but what about "ignorable whitespace"?Does not 
       * perform any whitespace normalization and ignores "ignorable 
       * whitespace".Should this be two methods instead?No. Keep it a read 
       * write attribute.What about the name? MS uses text and innerText. text 
       * conflicts with HTML DOM.Keep the current name, MS has a different 
       * name and different semantic.Should this be optional?No.Setting the 
       * text property on a Document, Document Type, or Notation node is an 
       * error for MS. How do we expose it? Exception? Which one?
       * (teleconference 23 May 2001) consistency with nodeValue. Remove 
       * Document from the list.
       * @exception DOMException
       *   NO_MODIFICATION_ALLOWED_ERR: Raised when the node is readonly.
       * @exception DOMException
       *   DOMSTRING_SIZE_ERR: Raised when it would return more characters than 
       *   fit in a <code>DOMString</code> variable on the implementation 
       *   platform.
       * @since DOM Level 3
       */
      public void setTextContent(String textContent)
                                       throws DOMException;
  
      /**
       * Returns whether this node is the same node as the given one.
       * <br>This method provides a way to determine whether two 
       * <code>Node</code> references returned by the implementation reference 
       * the same object. When two <code>Node</code> references are references 
       * to the same object, even if through a proxy, the references may be 
       * used completely interchangeably, such that all attributes have the 
       * same values and calling the same DOM method on either reference 
       * always has exactly the same effect.Do we really want to make this 
       * different from equals?Yes, change name from isIdentical to 
       * isSameNode. (Telcon 4 Jul 2000).Is this really needed if we provide a 
       * unique key?Yes, because the key is only unique within a document. 
       * (F2F 2 Mar 2001).Definition of 'sameness' is needed.
       * @param other The node to test against.
       * @return Returns <code>true</code> if the nodes are the same, 
       *   <code>false</code> otherwise.
       * @since DOM Level 3
       */
      public boolean isSameNode(Node other);
  
      /**
       * Look up the prefix associated to the given namespace URI, starting from 
       * this node.
       * <br>See  for details on the algorithm used by this method.Should this 
       * be optional?No.How does the lookup work? Is it based on the prefix of 
       * the nodes, the namespace declaration attributes, or a combination of 
       * both?See .
       * @param namespaceURI The namespace URI to look for.
       * @param useDefault  Indicates if the lookup mechanism should take into 
       *   account the default namespace or not. 
       * @return Returns an associated namespace prefix if found, 
       *   <code>null</code> if none is found and <code>useDefault</code> is 
       *   false, or <code>null</code> if not found or it is the default 
       *   namespace and <code>useDefault</code> is <code>true</code>. If more 
       *   than one prefix are associated to the namespace prefix, the 
       *   returned namespace prefix is implementation dependent.
       * @since DOM Level 3
       */
      public String lookupNamespacePrefix(String namespaceURI, 
                                          boolean useDefault);
  
      /**
       *  This method checks if the specified <code>namespaceURI</code> is the 
       * default namespace or not. 
       * @param namespaceURI The namespace URI to look for.
       * @return  <code>true</code> if the specified <code>namespaceURI</code> 
       *   is the default namespace, <code>false</code> otherwise. 
       * @since DOM Level 3
       */
      public boolean isDefaultNamespace(String namespaceURI);
  
      /**
       * Look up the namespace URI associated to the given prefix, starting from 
       * this node.
       * <br>See  for details on the algorithm used by this method.Name? May 
       * need to change depending on ending of the relative namespace URI 
       * reference nightmare.No need.Should this be optional?No.How does the 
       * lookup work? Is it based on the namespaceURI of the nodes, the 
       * namespace declaration attributes, or a combination of both?See .
       * @param prefix The prefix to look for. If this parameter is 
       *   <code>null</code>, the method will return the default namespace URI 
       *   if any.
       * @return Returns the associated namespace URI or <code>null</code> if 
       *   none is found.
       * @since DOM Level 3
       */
      public String lookupNamespaceURI(String prefix);
  
      /**
       * Tests whether two nodes are equal.
       * <br>This method tests for equality of nodes, not sameness (i.e., 
       * whether the two nodes are references to the same object) which can be 
       * tested with <code>Node.isSameNode</code>. All nodes that are the same 
       * will also be equal, though the reverse may not be true.
       * <br>Two nodes are equal if and only if the following conditions are 
       * satisfied: The two nodes are of the same type.The following string 
       * attributes are equal: <code>nodeName</code>, <code>localName</code>, 
       * <code>namespaceURI</code>, <code>prefix</code>, <code>nodeValue</code>
       * , <code>baseURI</code>. This is: they are both <code>null</code>, or 
       * they have the same length and are character for character identical.
       * The <code>attributes</code> <code>NamedNodeMaps</code> are equal. 
       * This is: they are both <code>null</code>, or they have the same 
       * length and for each node that exists in one map there is a node that 
       * exists in the other map and is equal, although not necessarily at the 
       * same index.The <code>childNodes</code> <code>NodeLists</code> are 
       * equal. This is: they are both <code>null</code>, or they have the 
       * same length and contain equal nodes at the same index. Note that 
       * normalization can affect equality; to avoid this, nodes should be 
       * normalized before being compared. 
       * <br>For two <code>DocumentType</code> nodes to be equal, the following 
       * conditions must also be satisfied: The following string attributes 
       * are equal: <code>publicId</code>, <code>systemId</code>, 
       * <code>internalSubset</code>.The <code>entities</code> 
       * <code>NamedNodeMaps</code> are equal.The <code>notations</code> 
       * <code>NamedNodeMaps</code> are equal. 
       * <br>On the other hand, the following do not affect equality: the 
       * <code>ownerDocument</code> attribute, the <code>specified</code> 
       * attribute for <code>Attr</code> nodes, the 
       * <code>isWhitespaceInElementContent</code> attribute for 
       * <code>Text</code> nodes, as well as any user data or event listeners 
       * registered on the nodes.Should this be optional?No.Should the deep 
       * parameter be dropped?Yes (Telcon Apr 3, 2002).
       * @param arg The node to compare equality with.
       * @return If the nodes, and possibly subtrees are equal, 
       *   <code>true</code> otherwise <code>false</code>.
       * @since DOM Level 3
       */
      public boolean isEqualNode(Node arg);
  
      /**
       * This method makes available a <code>Node</code>'s specialized interface 
       * (see ).What are the relations between Node.isSupported and 
       * Node3.getInterface?Should we rename this method (and also 
       * DOMImplementation.getInterface?)?getInterface can return a node that 
       * doesn't actually support the requested interface and will lead to a 
       * cast exception. Other solutions are returning null or throwing an 
       * exception.
       * @param feature The name of the feature requested (case-insensitive).
       * @return Returns an alternate <code>Node</code> which implements the 
       *   specialized APIs of the specified feature, if any, or 
       *   <code>null</code> if there is no alternate <code>Node</code> which 
       *   implements interfaces associated with that feature. Any alternate 
       *   <code>Node</code> returned by this method must delegate to the 
       *   primary core <code>Node</code> and not return results inconsistent 
       *   with the primary core <code>Node</code> such as <code>key</code>, 
       *   <code>attributes</code>, <code>childNodes</code>, etc.
       * @since DOM Level 3
       */
      public Node getInterface(String feature);
  
      /**
       * Associate an object to a key on this node. The object can later be 
       * retrieved from this node by calling <code>getUserData</code> with the 
       * same key.
       * @param key The key to associate the object to.
       * @param data The object to associate to the given key, or 
       *   <code>null</code> to remove any existing association to that key.
       * @param handler The handler to associate to that key, or 
       *   <code>null</code>.
       * @return Returns the <code>DOMUserData</code> previously associated to 
       *   the given key on this node, or <code>null</code> if there was none.
       * @since DOM Level 3
       */
      public Object setUserData(String key, 
                                Object data, 
                                UserDataHandler handler);
  
      /**
       * Retrieves the object associated to a key on a this node. The object 
       * must first have been set to this node by calling 
       * <code>setUserData</code> with the same key.
       * @param key The key the object is associated to.
       * @return Returns the <code>DOMUserData</code> associated to the given 
       *   key on this node, or <code>null</code> if there was none.
       * @since DOM Level 3
       */
      public Object getUserData(String key);
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/NodeList.java
  
  Index: NodeList.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * The <code>NodeList</code> interface provides the abstraction of an ordered 
   * collection of nodes, without defining or constraining how this collection 
   * is implemented. <code>NodeList</code> objects in the DOM are live.
   * <p>The items in the <code>NodeList</code> are accessible via an integral 
   * index, starting from 0.
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface NodeList {
      /**
       * Returns the <code>index</code>th item in the collection. If 
       * <code>index</code> is greater than or equal to the number of nodes in 
       * the list, this returns <code>null</code>.
       * @param index Index into the collection.
       * @return The node at the <code>index</code>th position in the 
       *   <code>NodeList</code>, or <code>null</code> if that is not a valid 
       *   index.
       */
      public Node item(int index);
  
      /**
       * The number of nodes in the list. The range of valid child node indices 
       * is 0 to <code>length-1</code> inclusive.
       */
      public int getLength();
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/Notation.java
  
  Index: Notation.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * This interface represents a notation declared in the DTD. A notation either 
   * declares, by name, the format of an unparsed entity (see section 4.7 of 
   * the XML 1.0 specification ), or is used for formal declaration of 
   * processing instruction targets (see section 2.6 of the XML 1.0 
   * specification ). The <code>nodeName</code> attribute inherited from 
   * <code>Node</code> is set to the declared name of the notation.
   * <p>The DOM Level 1 does not support editing <code>Notation</code> nodes; 
   * they are therefore readonly.
   * <p>A <code>Notation</code> node does not have any parent.adds a 
   * namespaceURI for notations?No. 1- notations are attached to a 
   * <code>DocumentType</code>. 2- what would be the key for notations in 
   * namednodemap? 
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface Notation extends Node {
      /**
       * The public identifier of this notation. If the public identifier was 
       * not specified, this is <code>null</code>.
       * <br> This attribute represents the property [public identifier] defined 
       * by the Notation Information Item in . 
       */
      public String getPublicId();
  
      /**
       * The system identifier of this notation. If the system identifier was 
       * not specified, this is <code>null</code>. This may be an absolute URI 
       * or not.
       * <br> This attribute represents the property [system identifier] defined 
       * by the Notation Information Item in . 
       */
      public String getSystemId();
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/ProcessingInstruction.java
  
  Index: ProcessingInstruction.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * The <code>ProcessingInstruction</code> interface represents a "processing 
   * instruction", used in XML as a way to keep processor-specific information 
   * in the text of the document. The property [notation] defined in  is not 
   * accessible from DOM Level 3 Core. 
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface ProcessingInstruction extends Node {
      /**
       * The target of this processing instruction. XML defines this as being 
       * the first token following the markup that begins the processing 
       * instruction.
       * <br> This attribute represents the property [target] defined in . 
       */
      public String getTarget();
  
      /**
       * The content of this processing instruction. This is from the first non 
       * white space character after the target to the character immediately 
       * preceding the <code>?&gt;</code>.
       * <br> This attribute represents the property [content] defined by the 
       * Processing Instruction Information Item in . 
       * @exception DOMException
       *   NO_MODIFICATION_ALLOWED_ERR: Raised when the node is readonly.
       */
      public String getData();
      /**
       * The content of this processing instruction. This is from the first non 
       * white space character after the target to the character immediately 
       * preceding the <code>?&gt;</code>.
       * <br> This attribute represents the property [content] defined by the 
       * Processing Instruction Information Item in . 
       * @exception DOMException
       *   NO_MODIFICATION_ALLOWED_ERR: Raised when the node is readonly.
       */
      public void setData(String data)
                                 throws DOMException;
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/Text.java
  
  Index: Text.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * The <code>Text</code> interface inherits from <code>CharacterData</code> 
   * and represents the textual content (termed character data in XML) of an 
   * <code>Element</code> or <code>Attr</code>. If there is no markup inside 
   * an element's content, the text is contained in a single object 
   * implementing the <code>Text</code> interface that is the only child of 
   * the element. If there is markup, it is parsed into the information items 
   * (elements, comments, etc.) and <code>Text</code> nodes that form the list 
   * of children of the element.
   * <p>When a document is first made available via the DOM, there is only one 
   * <code>Text</code> node for each block of text. Users may create adjacent 
   * <code>Text</code> nodes that represent the contents of a given element 
   * without any intervening markup, but should be aware that there is no way 
   * to represent the separations between these nodes in XML or HTML, so they 
   * will not (in general) persist between DOM editing sessions. The 
   * <code>normalize</code> method on <code>Node</code> merges any such 
   * adjacent <code>Text</code> objects into a single node for each block of 
   * text.
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface Text extends CharacterData {
      /**
       * Breaks this node into two nodes at the specified <code>offset</code>, 
       * keeping both in the tree as siblings. After being split, this node 
       * will contain all the content up to the <code>offset</code> point. A 
       * new node of the same type, which contains all the content at and 
       * after the <code>offset</code> point, is returned. If the original 
       * node had a parent node, the new node is inserted as the next sibling 
       * of the original node. When the <code>offset</code> is equal to the 
       * length of this node, the new node has no data.
       * @param offset The 16-bit unit offset at which to split, starting from 
       *   <code>0</code>.
       * @return The new node, of the same type as this node.
       * @exception DOMException
       *   INDEX_SIZE_ERR: Raised if the specified offset is negative or greater 
       *   than the number of 16-bit units in <code>data</code>.
       *   <br>NO_MODIFICATION_ALLOWED_ERR: Raised if this node is readonly.
       */
      public Text splitText(int offset)
                            throws DOMException;
  
      /**
       * Returns whether this text node contains whitespace in element content, 
       * often abusively called "ignorable whitespace".An implementation can 
       * only return <code>true</code> if, one way or another, it has access 
       * to the relevant information (e.g., the DTD or schema).
       * <br> This attribute represents the property [element content 
       * whitespace] defined in . 
       * @since DOM Level 3
       */
      public boolean getIsWhitespaceInElementContent();
  
      /**
       * Returns all text of <code>Text</code> nodes logically-adjacent text 
       * nodes to this node, concatenated in document order.
       * @since DOM Level 3
       */
      public String getWholeText();
  
      /**
       * Substitutes the a specified text for the text of the current node and 
       * all logically-adjacent text nodes.
       * <br>This method returns the node in the hierarchy which received the 
       * replacement text, which is null if the text was empty or is the 
       * current node if the current node is not read-only or otherwise is a 
       * new node of the same type as the current node inserted at the site of 
       * the replacement. All logically-adjacent text nodes are removed 
       * including the current node unless it was the recipient of the 
       * replacement text.
       * <br>Where the nodes to be removed are read-only descendants of an 
       * <code>EntityReference</code>, the <code>EntityReference</code> must 
       * be removed instead of the read-only nodes. If any 
       * <code>EntityReference</code> to be removed has descendants that are 
       * not <code>EntityReference</code>, <code>Text</code>, or 
       * <code>CDATASection</code> nodes, the <code>replaceWholeText</code> 
       * method must fail before performing any modification of the document, 
       * raising a <code>DOMException</code> with the code 
       * <code>NO_MODIFICATION_ALLOWED_ERR</code>.
       * @param content The content of the replacing <code>Text</code> node.
       * @return The <code>Text</code> node created with the specified content.
       * @exception DOMException
       *   NO_MODIFICATION_ALLOWED_ERR: Raised if one of the <code>Text</code> 
       *   nodes being replaced is readonly.
       * @since DOM Level 3
       */
      public Text replaceWholeText(String content)
                                   throws DOMException;
  
  }
  
  
  
  1.1                  xml-xerces/java/src/dom3/org/w3c/dom/UserDataHandler.java
  
  Index: UserDataHandler.java
  ===================================================================
  /*
   * Copyright (c) 2002 World Wide Web Consortium,
   * (Massachusetts Institute of Technology, Institut National de
   * Recherche en Informatique et en Automatique, Keio University). All
   * Rights Reserved. This program is distributed under the W3C's Software
   * Intellectual Property License. This program is distributed in the
   * hope that it will be useful, but WITHOUT ANY WARRANTY; without even
   * the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
   * PURPOSE.
   * See W3C License http://www.w3.org/Consortium/Legal/ for more details.
   */
  
  package org.w3c.dom;
  
  /**
   * When associating an object to a key on a node using <code>setUserData</code>
   *  the application can provide a handler that gets called when the node the 
   * object is associated to is being cloned or imported. This can be used by 
   * the application to implement various behaviors regarding the data it 
   * associates to the DOM nodes. This interface defines that handler. 
   * <p>See also the <a href='http://www.w3.org/TR/2002/WD-DOM-Level-3-Core-20020409'>Document Object Model (DOM) Level 3 Core Specification</a>.
   */
  public interface UserDataHandler {
      // OperationType
      /**
       * The node is cloned.
       */
      public static final short NODE_CLONED               = 1;
      /**
       * The node is imported.
       */
      public static final short NODE_IMPORTED             = 2;
      /**
       * The node is deleted.
       */
      public static final short NODE_DELETED              = 3;
      /**
       * The node is renamed.
       */
      public static final short NODE_RENAMED              = 4;
  
      /**
       * This method is called whenever the node for which this handler is 
       * registered is imported or cloned.
       * @param operation Specifies the type of operation that is being 
       *   performed on the node.
       * @param key Specifies the key for which this handler is being called. 
       * @param data Specifies the data for which this handler is being called. 
       * @param src Specifies the node being cloned, imported, or renamed. This 
       *   is <code>null</code> when the node is being deleted.
       * @param dst Specifies the node newly created if any, or 
       *   <code>null</code>.
       */
      public void handle(short operation, 
                         String key, 
                         Object data, 
                         Node src, 
                         Node dst);
  
  }
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: xerces-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: xerces-cvs-help@xml.apache.org