[jdom-interest] Merging jdoms

Jason Hunter jhunter at collab.net
Wed May 9 14:04:45 PDT 2001


> Is it possible for Element.addContent(Element elt) to do something like
> this?
> 
> if (elt.getParent() != null) {
>     elt.detach();
> }
> // go on with adding elt
> 
> Or, alternatively, make it throw an exception when trying to do that.

It already throws an exception if the parent isn't null.

-jh-



More information about the jdom-interest mailing list