/[classpath]/classpath/gnu/xml/dom/DomNamedNodeMap.java
ViewVC logotype

Diff of /classpath/gnu/xml/dom/DomNamedNodeMap.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.1 by mark, Thu Dec 23 22:38:43 2004 UTC revision 1.2 by dog, Thu Feb 10 17:21:25 2005 UTC
# Line 37  exception statement from your version. * Line 37  exception statement from your version. *
37    
38  package gnu.xml.dom;  package gnu.xml.dom;
39    
40    import org.w3c.dom.DOMException;
41  import org.w3c.dom.NamedNodeMap;  import org.w3c.dom.NamedNodeMap;
42  import org.w3c.dom.Node;  import org.w3c.dom.Node;
43    
# Line 166  public class DomNamedNodeMap Line 167  public class DomNamedNodeMap
167    {    {
168      if (readonly)      if (readonly)
169        {        {
170          throw new DomEx(DomEx.NO_MODIFICATION_ALLOWED_ERR);          throw new DomDOMException(DOMException.NO_MODIFICATION_ALLOWED_ERR);
171        }        }
172    
173      DomNode node = (DomNode) arg;      DomNode node = (DomNode) arg;
174      if (node.owner != owner.owner)      if (node.owner != owner.owner)
175        {        {
176          throw new DomEx(DomEx.WRONG_DOCUMENT_ERR);          throw new DomDOMException(DOMException.WRONG_DOCUMENT_ERR);
177        }        }
178      if (node.nodeType != type)      if (node.nodeType != type)
179        {        {
180          throw new DomEx(DomEx.HIERARCHY_REQUEST_ERR);          throw new DomDOMException(DOMException.HIERARCHY_REQUEST_ERR);
181        }        }
182      if (node.nodeType == Node.ATTRIBUTE_NODE)      if (node.nodeType == Node.ATTRIBUTE_NODE)
183        {        {
184          DomNode element = node.parent;          DomNode element = node.parent;
185          if (element != null && element != owner)          if (element != null && element != owner)
186            {            {
187              throw new DomEx(DomEx.INUSE_ATTRIBUTE_ERR);              throw new DomDOMException(DOMException.INUSE_ATTRIBUTE_ERR);
188            }            }
189          node.parent = owner;          node.parent = owner;
190          node.depth = owner.depth + 1;          node.depth = owner.depth + 1;
# Line 302  public class DomNamedNodeMap Line 303  public class DomNamedNodeMap
303    {    {
304      if (readonly)      if (readonly)
305        {        {
306          throw new DomEx(DomEx.NO_MODIFICATION_ALLOWED_ERR);          throw new DomDOMException(DOMException.NO_MODIFICATION_ALLOWED_ERR);
307        }        }
308    
309      // report attribute REMOVAL event?      // report attribute REMOVAL event?
# Line 369  public class DomNamedNodeMap Line 370  public class DomNamedNodeMap
370              return ctx;              return ctx;
371            }            }
372        }            }    
373      throw new DomEx(DomEx.NOT_FOUND_ERR);      throw new DomDOMException(DOMException.NOT_FOUND_ERR);
374    }    }
375        
376    String getDefaultValue(String name)    String getDefaultValue(String name)

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26