Main Page Packages Class Hierarchy Compound List File List Compound Members

# noderemovechildgetnodename Class Reference

Inherits DOMTestCase.

List of all members.

## Public Methods
| noderemovechildgetnodename (DOMTestDocumentBuilderFactory factory)
void | runTest () throws java.lang.Throwable
String | getTargetURI ()
## Static Public Methods
void | main (String[] args)

## Detailed Description

The "removeChild(oldChild)" method returns the node being removed.

Remove the first child of the second employee and check the NodeName returned by the "removeChild(oldChild)" method. The returned node should have a NodeName equal to "text".

Author:
  NIST , Mary Brady

See also:
  http://www.w3.org/TR/1998/REC-DOM-Level-1-19981001/level-one-core#ID-F68D095 , http://www.w3.org/TR/1998/REC-DOM-Level-1-19981001/level-one-core#ID-1734834066

Definition at line 46 of file noderemovechildgetnodename.java.

## Constructor & Destructor Documentation

noderemovechildgetnodename::noderemovechildgetnodename | ( | DOMTestDocumentBuilderFactory | factory | ) | `[inline]`

| Definition at line 48 of file noderemovechildgetnodename.java.
    00049  {
    00050       super(factory);
    00051
    00052    }

## Member Function Documentation

String noderemovechildgetnodename::getTargetURI | ( |  | ) | `[inline, virtual]`

| Reimplemented from DOMTest. Definition at line 83 of file noderemovechildgetnodename.java.
    00083                                 {
    00084       return "http://www.w3.org/2001/DOM-Test-Suite/level1/core/noderemovechildgetnodename";
    00085    }

void noderemovechildgetnodename::main | ( | String | args[] | ) | `[inline, static]`

| Definition at line 86 of file noderemovechildgetnodename.java. References DOMTestCase::doMain().
    00086                                           {
    00087         DOMTestCase.doMain(noderemovechildgetnodename.class,args);
    00088    }

void noderemovechildgetnodename::runTest | ( |  | ) | `[inline, virtual]`

| Reimplemented from DOMTestCase. Definition at line 54 of file noderemovechildgetnodename.java. References DOMTestCase::assertEquals(), DOMTest::isIgnoringElementContentWhitespace(), and DOMTest::load().
    00054                                                     {
    00055       Document doc;
    00056       NodeList elementList;
    00057       Node employeeNode;
    00058       NodeList childList;
    00059       Node oldChild;
    00060       Node removedChild;
    00061       String childName;
    00062       doc = load("staff");
    00063       elementList = doc.getElementsByTagName("employee");
    00064       employeeNode = elementList.item(1);
    00065       childList = employeeNode.getChildNodes();
    00066       oldChild = childList.item(0);
    00067       removedChild = employeeNode.removeChild(oldChild);
    00068       childName = removedChild.getNodeName();
    00069
    00070         if(
    00071         isIgnoringElementContentWhitespace()
    00072         ) {
    00073         assertEquals("nowhitespace","employeeId",childName);
    00074
    00075         }
    00076
    00077                 else {
    00078                         assertEquals("whitespace","#text",childName);
    00079
    00080                 }
    00081
    00082    }

The documentation for this class was generated from the following file:

- noderemovechildgetnodename.java