[jdom-interest] Re: Can't we all get along? :) -- [is] getChild() vs.getChildElements()

tsasala at hifusion.com tsasala at hifusion.com
Fri Aug 4 09:21:04 PDT 2000

	Generally speaking I think of findChildXXXX as a deep search,
and a getChildXXXX as a 1 depth search.  JDOM has no findXXXXX
functions (that I know of).


Patrick Dowler wrote:
> On Thu, 03 Aug 2000, Elliotte Rusty Harold wrote:
> [concerning "getElement"]
> > I can certainly live with it, though I still prefer
> > getChildElement(). It's more descriptive and easier to read. There
> > are other elements in the document that are not children; e.g. the
> > parent, ancestor, and sibling elements.  I can see someone thinking
> > that getElement() searches any or all of these or even returns the
> > element itself.
> Really? That seems like a stretch... I really doubt anyone would expect
> "get" to search anywhere but under the target Element. Searching deeper
> means using XPath or a search algorithm (tree-walker).
> There is no end if you start thinking that way: "getSibling"? "getUncle"?
> "getNephew"? "getGrandChild"? "getSecondCousinTwiceRemoved" :-)
> --
> Patrick Dowler
> Canadian Astronomy Data Centre
> _______________________________________________
> To control your jdom-interest membership:
> http://lists.denveronline.net/mailman/options/jdom-interest/youraddr@yourhost.com

More information about the jdom-interest mailing list