--- Hans Prueller <[EMAIL PROTECTED]> wrote: > is is the normal case that an Actions getXXX() > method is called every time a > velocity-result template uses the $XXX variable? > > if my action has a method, say HashMap > getLabelsForType() and it is used in > velocity result like > > #foreach ($type in $types) > <td> $labelsForType.get($type) </td> > #end > > the method getLabelsForType is called for every > iteration of the foreach > loop. I tought the returned HashMap of > getLabelsForType() is > put into the velocity context before rendering and > thats it... > > is that my mistake or is there a deeper sense???
Your getter could have side effects. To avoid getter calls, just store your hash map in reference outside your loop. regards, ===== ----[ Konstantin Pribluda ( ko5tik ) ]---------------- Zu Verstärkung meines Teams suche ich ab Sofort einen Softwareentwickler[In] für die Festanstellung. Arbeitsort: Mainz Skills: Programieren, Kentnisse in OpenSource-Bereich ----[ http://www.pribluda.de ]------------------------ __________________________________ Do you Yahoo!? Yahoo! Mail SpamGuard - Read only the mail you want. http://antispam.yahoo.com/tools ------------------------------------------------------- SF.Net is sponsored by: Speed Start Your Linux Apps Now. Build and deploy apps & Web services for Linux with a free DVD software kit from IBM. Click Now! http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click _______________________________________________ Opensymphony-webwork mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/opensymphony-webwork