Main Page   Packages   Class Hierarchy   Compound List   File List   Compound Members  

nodelistindexgetlengthofemptylist Class Reference

Inherits DOMTestCase.

List of all members.

Public Methods

 nodelistindexgetlengthofemptylist (DOMTestDocumentBuilderFactory factory)
void runTest () throws java.lang.Throwable
String getTargetURI ()

Static Public Methods

void main (String[] args)


Detailed Description

The "getLength()" method returns the number of nodes in the list.(Test for EMPTY list)

Create a list of all the children of the Text node inside the first child of the third employee and invoke the "getLength()" method. It should contain the value 0.

Author:
NIST , Mary Brady
See also:
http://www.w3.org/TR/1998/REC-DOM-Level-1-19981001/level-one-core#ID-203510337

Definition at line 45 of file nodelistindexgetlengthofemptylist.java.


Constructor & Destructor Documentation

nodelistindexgetlengthofemptylist::nodelistindexgetlengthofemptylist DOMTestDocumentBuilderFactory    factory [inline]
 

Definition at line 47 of file nodelistindexgetlengthofemptylist.java.

00048  {
00049       super(factory);
00050 
00051    }


Member Function Documentation

String nodelistindexgetlengthofemptylist::getTargetURI   [inline, virtual]
 

Reimplemented from DOMTest.

Definition at line 71 of file nodelistindexgetlengthofemptylist.java.

00071                                 {
00072       return "http://www.w3.org/2001/DOM-Test-Suite/level1/core/nodelistindexgetlengthofemptylist";
00073    }

void nodelistindexgetlengthofemptylist::main String    args[] [inline, static]
 

Definition at line 74 of file nodelistindexgetlengthofemptylist.java.

References DOMTestCase::doMain().

00074                                           {
00075         DOMTestCase.doMain(nodelistindexgetlengthofemptylist.class,args);
00076    }

void nodelistindexgetlengthofemptylist::runTest   [inline, virtual]
 

Reimplemented from DOMTestCase.

Definition at line 53 of file nodelistindexgetlengthofemptylist.java.

References DOMTestCase::assertSize(), and DOMTest::load().

00053                                                     {
00054       Document doc;
00055       NodeList elementList;
00056       Node employeeNode;
00057       NodeList employeeList;
00058       Node childNode;
00059       Node textNode;
00060       NodeList textList;
00061       doc = load("staff");
00062       elementList = doc.getElementsByTagName("employee");
00063       employeeNode = elementList.item(2);
00064       employeeList = employeeNode.getChildNodes();
00065       childNode = employeeList.item(1);
00066       textNode = childNode.getFirstChild();
00067       textList = textNode.getChildNodes();
00068       assertSize("nodelistIndexGetLengthOfEmptyListAssert",0,textList);
00069       
00070    }


The documentation for this class was generated from the following file:
Generated on Thu Feb 14 19:47:05 2002 for DOM Level 1 Core Test Suite by doxygen1.2.13.1 written by Dimitri van Heesch, © 1997-2001