Main Page   Packages   Class Hierarchy   Compound List   File List   Compound Members  

attrnotspecifiedvalue Class Reference

Inherits DOMTestCase.

List of all members.

Public Methods

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

Static Public Methods

void main (String[] args)


Detailed Description

The "getSpecified()" method for an Attr node should be set to false if the attribute was not explicitly given a value. Retrieve the attribute named "street" from the last child of of the first employee and examine the value returned by the "getSpecified()" method. This test uses the "getNamedItem(name)" method from the NamedNodeMap interface.

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

Definition at line 46 of file attrnotspecifiedvalue.java.


Constructor & Destructor Documentation

attrnotspecifiedvalue::attrnotspecifiedvalue DOMTestDocumentBuilderFactory    factory [inline]
 

Definition at line 48 of file attrnotspecifiedvalue.java.

00049  {
00050       super(factory);
00051 
00052    }


Member Function Documentation

String attrnotspecifiedvalue::getTargetURI   [inline, virtual]
 

Reimplemented from DOMTest.

Definition at line 70 of file attrnotspecifiedvalue.java.

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

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

Definition at line 73 of file attrnotspecifiedvalue.java.

References DOMTestCase::doMain().

00073                                           {
00074         DOMTestCase.doMain(attrnotspecifiedvalue.class,args);
00075    }

void attrnotspecifiedvalue::runTest   [inline, virtual]
 

Reimplemented from DOMTestCase.

Definition at line 54 of file attrnotspecifiedvalue.java.

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

00054                                                     {
00055       Document doc;
00056       NodeList addressList;
00057       Node testNode;
00058       NamedNodeMap attributes;
00059       Attr streetAttr;
00060       boolean state;
00061       doc = load("staff");
00062       addressList = doc.getElementsByTagName("address");
00063       testNode = addressList.item(0);
00064       attributes = testNode.getAttributes();
00065       streetAttr = (Attr)attributes.getNamedItem("street");
00066       state = streetAttr.getSpecified();
00067       assertFalse("attrNotSpecifiedValueAssert",state);
00068 
00069    }


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