the getTemp/setTemp _seems_ more static than a message to a screen. it seems
to put data out into a session type hashtable which can be retrieved by any
forms.  for example, i have a navbar that displays the status of an item.
if i want to edit an item, and that edit crosses multiple screens, i can put
the item into the "temp" and then all the screens can get the items's status
from there.  just one small example thus far.

again, thoughts/comments from the veterans are MOST welcome.

> -----Original Message-----
> From: Johnny Quazar [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, March 05, 2003 12:26 PM
> To: Turbine Users List
> Subject: Re: using session data
> 
> 
> Hey Mark,
> 
> I too will be interested to see what the more experienced folks have 
> to say. I settled for using messages, at least in some cases:
> 
> Action:
> 
>    data.setMessage("myMessageType=" + dataToPass);
>    TemplateScreen.setTemplate(data, "MyScreen.vm");
> 
> Screen:
>    if (data.hasMessage()) {
>      String msg = data.getMessage();
>      // use StringTokenizer to check and parse the data
>      // if appropriate, add something to context
> 
> Flexible, perhaps lame. Seems cheap and easy though, and the scope is 
> much more limited than set/getTemp.
> 
> 
> At 12:05 PM -0500 3/5/03, Mark Lybarger wrote:
> >i recently started to use $data.getUser().getTemp("tempObject") in my
> >velocity template, and data.getUser().setTemp("tempObject") 
> in my action
> >classes. 
> >
> >Are there any drawbacks to using this approach of putting 
> data out there for
> >the templates to use?  this seems _much_ easier than using our former
> >approach of making each action class put data into the 
> context that the next
> >form will need, so there's got to be a drawback somewhere.
> >
> >
> >Mark Lybarger
> >[EMAIL PROTECTED]
> >CBC Companies
> >614.442.3741
> >
> >---
> >Outgoing mail is certified Virus Free.
> >Checked by AVG anti-virus system (http://www.grisoft.com).
> >Version: 6.0.459 / Virus Database: 258 - Release Date: 2/25/2003
> >
> >
> >---------------------------------------------------------------------
> >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]
> 
> ---
> Incoming mail is certified Virus Free.
> Checked by AVG anti-virus system (http://www.grisoft.com).
> Version: 6.0.459 / Virus Database: 258 - Release Date: 2/25/2003
>  
> 

---
Outgoing mail is certified Virus Free.
Checked by AVG anti-virus system (http://www.grisoft.com).
Version: 6.0.459 / Virus Database: 258 - Release Date: 2/25/2003
 

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to