Hi,

for the following code (xerces2-J, DOM model)

case Node.TEXT_NODE:
    String str = getNodeValue();
    if ( ( !str.equals("\n")) && (!str.equals(null)) ) {
        // do something
    }

I'm trying to get rid of the empty text child nodes, like:
<tag1>
    <tage2>
        TextB
    </tag2>
</tag1>

The above code returns back 3 children nodes for element <tag1>: TEXT
(empty), ELEMENT (tag2), TEXT(empty).

Can anyone help me out of how to get rid of the TEXT(empty) child nodes?

Thanks!


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to