Re: Was the JDom support removed/deprecated?

Daniel Dekany <[email protected]>
Newsgroups gmane.comp.web.freemarker.user
Message-ID <[email protected]>
Saturday, January 24, 2009, 5:49:58 PM, Jeremy Chone wrote:

> I am using ROME (RSS utility) which return JDom elements it some of
> their apis. When looking at Freemarker, I found the NodeListModel
> for JDOM, but it says it is deprecated in favor of NodeModel which seems to support only w3c DOM.
>
> Am I missing something? 
>
> Also, I was under the impression that if one of my bean/object
> returned a XML Element (JDOM or W3C Dom) the wrapping into a
> NodeListModel or NodeModel would be automatic. On this one I think I
> am missing something. Any explanation greatly appreciated. 

The wrapper for JDOM nodes is not maintained anymore, and will be
removed in 2.4. You should use W3C DOM... but it seems it's not
possible in you case. However, if the current JDOM wrapper works for
you, you can grab it from the source code, even rename the package to
com.yourcompany.freemarker.jdom or something, and put it into your own
jar, or pack it as part of your project. Then it will work with
FreeMarker 2.4 as well, also you can tweak it accord your needs. Using
custom wrappers is a normal (intended) practice after all.

-- 
Best regards,
 Daniel Dekany


------------------------------------------------------------------------------
This SF.net email is sponsored by:
SourcForge Community
SourceForge wants to tell your story.
http://p.sf.net/sfu/sf-spreadtheword
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.