Re: FreeMarker for newbies
Angelo zerr <[email protected]> Wed, 10 Jul 2013 16:00:30 +0200
| Newsgroups | gmane.comp.web.freemarker.user |
|---|---|
| Message-ID | <CAKLdLg9vFMzJTZXwv+DT5sZf5XiYLHiS8H7+-JS+T77XC81Tyg@mail.gmail.com> |
2013/7/10 Eyal <[email protected]> > Hi Angelo, > > Thanks for the algorithm!! > You are welcome. > > But I have to start with a simpler and technical question, when I want to > process the template, I need to direct it to a stream (In the samples it is > the System.out), how do I tell it to process the template to an XML > element? > 1) Use StringWriter or ByteArrayOuptStream to stores the generated XML element (generated with FM). 2) Load DOM document by using the StringWriter or ByteArrayOuptStream. 3) Get the DOM element (root element) of this DOM. Perhaps using SAX Parser could be improved the memory, but I have never done that. Regards Angelo > > Thanks > Eyal > > > > -- > View this message in context: > http://freemarker.624813.n4.nabble.com/FreeMarker-for-newbies-tp4654620p4654624.html > Sent from the freemarker-user mailing list archive at Nabble.com. > > > ------------------------------------------------------------------------------ > See everything from the browser to the database with AppDynamics > Get end-to-end visibility with application monitoring from AppDynamics > Isolate bottlenecks and diagnose root cause in seconds. > Start your free trial of AppDynamics Pro today! > http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk > _______________________________________________ > FreeMarker-user mailing list > [email protected] > https://lists.sourceforge.net/lists/listinfo/freemarker-user > ------------------------------------------------------------------------------ See everything from the browser to the database with AppDynamics Get end-to-end visibility with application monitoring from AppDynamics Isolate bottlenecks and diagnose root cause in seconds. Start your free trial of AppDynamics Pro today! http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk _______________________________________________ FreeMarker-user mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/freemarker-user