[jdom-interest] a question about node type

Grzegorz Kaczor grzegorz.kaczor at computaris.com
Wed Dec 6 02:48:48 PST 2006


JDOM is a very convenient interface to manipulate XML elements but I 
think it lacks one useful functionality that is present in W3C DOM 
implementation - a node type distinction available from Content class.

Let's say I want to perform something for each node (and for each type 
of node a different activity) - for example I want to replace all 
lowercase 'a' letters to uppercase ones - in element text content, in 
attribute values, in CDATA sections and so on (this is an exemplary 
action). Do I have to use reflection for that?

In W3C DOM I can use getNodeType() to distinguish node types and perform 
the replace recursively. How can I do the same using JDOM and not using 

Best Regards,

This email is subject to Computaris email terms of use: http://www.computaris.com/email_terms.html

More information about the jdom-interest mailing list