[jdom-interest] getChildText() question

Mike Hogarth mike at hogarth.org
Sun Jan 20 09:52:19 PST 2002


I am finding a node's text by using the following command
System.out.println(root.getChild("PubmedArticle").getChild("
MedlineCitation").getChild("Article").getChild("Abstract").g
etChild("AbstractText").getText());

Is there a simpler way other than navigating each node down
the chain?  For examle, is there a quick way to find the
first element named "AbstractText", then get its text?


--Mike H





More information about the jdom-interest mailing list