Thank you, I will look into mergeTemplate() as you suggest.
----- Original Message ----- From: "Nathan Bubna" <[EMAIL PROTECTED]> To: "Velocity Users List" <[email protected]> Sent: Monday, January 03, 2005 11:57 AM Subject: Re: Multiple .VMs > i'm not quite sure what you mean by "processed over and over". do you > mean parsed from file over and over? or do you mean "merged with > variable data" over and over? > > either way, the answer is yes, but the latter is the typical use case > and thus quite speedy. basically, a template is parsed from a file > and cached in parsed form. it is then repeatedly merged with > dynamically variable data for each call to the mergeTemplate() method. > typically, these calls are made per servlet request, but i see no > reason it couldn't be adapted for pushlets. > > while there are those who use Velocity rather statically to generate > files and then merely serve/use the generated files rather than do > things on the fly (Anakia and Texen are typically used thus), Velocity > is capable of much more. > > On Sun, 2 Jan 2005 22:42:12 -0600, William Fuller > <[EMAIL PROTECTED]> wrote: > > I mentioned in an earlier post that I was attempting to convert pushlets to > > use Velocity. I did some experimenting and I have a hybrid Velocity/JSP > > version running. Needless to say I want to NIX the JSP. > > > > I need to load a page with several hidden frames, each hidden frame wanting > > to point at a different .VM. I want the same servlet that generated the > > page with the hidden frames to serve the templates. The catch is, to do the > > "pushlet" thing, the template will need to be processed over and over again. > > > > class extends velocity servlet... > > for( int i = 0; i < 10; i++ ) > > // database type stuff... > > get.template() sort of thing > > > > Is this something that Velocity can handle? > > > > I would appreciate any advice on this topic before finding out the HARD way. > > (-; > > > > Thank you in advance. > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
