Public Methods | |
| namednodemapgetnameditem (DOMTestDocumentBuilderFactory factory) | |
| void | runTest () throws java.lang.Throwable |
| String | getTargetURI () |
Static Public Methods | |
| void | main (String[] args) |
Retrieve the second employee and create a NamedNodeMap listing of the attributes of the last child. Once the list is created an invocation of the "getNamedItem(name)" method is done with name="domestic". This should result in the domestic Attr node being returned.
Definition at line 47 of file namednodemapgetnameditem.java.
|
|
Definition at line 49 of file namednodemapgetnameditem.java.
00050 {
00051 super(factory);
00052
00053 }
|
|
|
Reimplemented from DOMTest. Definition at line 71 of file namednodemapgetnameditem.java.
00071 {
00072 return "http://www.w3.org/2001/DOM-Test-Suite/level1/core/namednodemapgetnameditem";
00073 }
|
|
|
Definition at line 74 of file namednodemapgetnameditem.java. References DOMTestCase::doMain().
00074 {
00075 DOMTestCase.doMain(namednodemapgetnameditem.class,args);
00076 }
|
|
|
Reimplemented from DOMTestCase. Definition at line 55 of file namednodemapgetnameditem.java. References DOMTestCase::assertEquals(), and DOMTest::load().
00055 {
00056 Document doc;
00057 NodeList elementList;
00058 Node testEmployee;
00059 NamedNodeMap attributes;
00060 Attr domesticAttr;
00061 String attrName;
00062 doc = load("staff");
00063 elementList = doc.getElementsByTagName("address");
00064 testEmployee = elementList.item(1);
00065 attributes = testEmployee.getAttributes();
00066 domesticAttr = (Attr)attributes.getNamedItem("domestic");
00067 attrName = domesticAttr.getNodeName();
00068 assertEquals("namednodemapGetNamedItemAssert","domestic",attrName);
00069
00070 }
|
1.2.13.1 written by Dimitri van Heesch,
© 1997-2001