Main Page Packages Class Hierarchy Compound List File List Compound Members

# textwithnomarkup Class Reference

Inherits DOMTestCase.

List of all members.

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

## Detailed Description

If there is not any markup inside an Element or Attr node content, then the text is contained in a single object implementing the Text interface that is the only child of the element.

Retrieve the textual data from the second child of the third employee. That Text node contains a block of multiple text lines without markup, so they should be treated as a single Text node. The "getNodeValue()" method should contain the combination of the two lines.

Author:
  NIST , Mary Brady

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

Definition at line 49 of file textwithnomarkup.java.

## Constructor & Destructor Documentation

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

| Definition at line 51 of file textwithnomarkup.java.
    00052  {
    00053       super(factory);
    00054
    00055    }

## Member Function Documentation

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

| Reimplemented from DOMTest. Definition at line 71 of file textwithnomarkup.java.
    00071                                 {
    00072       return "http://www.w3.org/2001/DOM-Test-Suite/level1/core/textwithnomarkup";
    00073    }

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

| Definition at line 74 of file textwithnomarkup.java. References DOMTestCase::doMain().
    00074                                           {
    00075         DOMTestCase.doMain(textwithnomarkup.class,args);
    00076    }

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

| Reimplemented from DOMTestCase. Definition at line 57 of file textwithnomarkup.java. References DOMTestCase::assertEquals(), and DOMTest::load().
    00057                                                     {
    00058       Document doc;
    00059       NodeList elementList;
    00060       Node nameNode;
    00061       Node nodeV;
    00062       String value;
    00063       doc = load("staff");
    00064       elementList = doc.getElementsByTagName("name");
    00065       nameNode = elementList.item(2);
    00066       nodeV = nameNode.getFirstChild();
    00067       value = nodeV.getNodeValue();
    00068       assertEquals("textWithNoMarkupAssert","Roger\n Jones",value);
    00069
    00070    }

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

- textwithnomarkup.java