Java Mailing List Archive

http://www.junlu.com/

Home » Home (12/2007) » JDOM User »

[jdom-interest] Parameter ordering in canContain

Bradley S. Huffman

2004-02-18

Replies:

Is there some reason the order of parameters in canContain is different
from every other JDOM method that takes a index? And no other JDOM
method declares that it throws a RuntimeException so canContain shouldn't.

And what is the purpose of this method anyway, other than to save a instanceof
on content addition, which could have been accomplished by setting a boolean
"isElement" on ContentList construction? If it for notification of events, I'd
prefer XOM's methodology of checkAddChild/checkRemoveChild, checkAddAttribute/
checkRemoveChild, and so on. Which don't contain any well-formness test, so
you cann't screw anything up by overriding them.

Brad
_______________________________________________
To control your jdom-interest membership:
http://lists.denveronline.net/mailman/options/jdom-interest/youraddr@(protected)


©2008 junlu.com - Jax Systems, LLC, U.S.A.