Even if you are using singleton controllers (say FormBeanUser), you
still need to keep the Form object somewhere - that would be the
HttpSession attribute collection.  Any data shared inside a singleton
controller will be shared among all requests from all users and would
need to be protected by synchronization.

Assuming you are trying to populate a form across several invocations
using FormBeanUser, just write makeFormBean() like this:

Get bean out of session attributes
If bean does not exist
    Create bean
    Save in session attributes

Jeff Schnitzer
[EMAIL PROTECTED]

> -----Original Message-----
> From: Scott Chun [mailto:[EMAIL PROTECTED]
> Sent: Thursday, March 20, 2003 11:47 AM
> To: [EMAIL PROTECTED]
> Subject: RE: [Mav-user] Multiple shunts
> 
> So far, I haven't found anything that is difficult with Maverick!
> 
> I have a question about the use of singleton and throwaway
controllers. It
> appears to me that one use of singleton controllers would be to
maintain
> stateful information across controller invocations.
> 
> Would this be an approriate use of these controllers or do you
recommend
> using
> the standard J2EE practice of HttpSession or a SessionBean?
> 
> -Scott
> 
> >>> [EMAIL PROTECTED] 03/19/03 05:21PM >>>
> The Maverick distribution includes an example LanguageShunt and a
> trivial sample application that uses it.
> 
> The shunt mechanism can accommodate composition, but you will have to
> build the composite yourself.  ShuntFactory implementations are very
> easy to build.  Since everyone's defaulting logic will likely be
> different, I didn't try to put a composite in the distribution.
> 
> Jeff
> 
> > -----Original Message-----
> > From: Scott Chun [mailto:[EMAIL PROTECTED]
> > Sent: Wednesday, March 19, 2003 3:07 PM
> > To: [EMAIL PROTECTED]
> > Subject: [Mav-user] Multiple shunts
> >
> > Is it possible to use more than one shunt per Maverick app (i.e. one
> for
> > language and another for browser type)? If yes:
> >
> > 1) How do I declare it in the Maverick configuration file
> > 2) How do I define the modes
> >
> > Thanks!
> >
> >
>
------------------------------------------------------------------------
> --
> > ----
> > This message may contain confidential information, and is intended
> only
> > for the use of the individual(s) to whom it is addressed.
> >
> >
> >
>
========================================================================
> ==
> > ====
> >
> >
> >
> > -------------------------------------------------------
> > This SF.net email is sponsored by: Does your code think in ink?
> > You could win a Tablet PC. Get a free Tablet PC hat just for
playing.
> > What are you waiting for?
> > http://ads.sourceforge.net/cgi-bin/redirect.pl?micr5043en
> > [INVALID FOOTER]
> 
> 
> 
> -------------------------------------------------------
> This SF.net email is sponsored by: Does your code think in ink?
> You could win a Tablet PC. Get a free Tablet PC hat just for playing.
> What are you waiting for?
> http://ads.sourceforge.net/cgi-bin/redirect.pl?micr5043en
> [INVALID FOOTER]
> 
> 
>
------------------------------------------------------------------------
--
> ----
> This message may contain confidential information, and is intended
only
> for the use of the individual(s) to whom it is addressed.
> 
> 
>
========================================================================
==
> ====
> 
> 
> 
> -------------------------------------------------------
> This SF.net email is sponsored by: Tablet PC.
> Does your code think in ink? You could win a Tablet PC.
> Get a free Tablet PC hat just for playing. What are you waiting for?
> http://ads.sourceforge.net/cgi-bin/redirect.pl?micr5043en
> [INVALID FOOTER]



-------------------------------------------------------
This SF.net email is sponsored by: Tablet PC.
Does your code think in ink? You could win a Tablet PC.
Get a free Tablet PC hat just for playing. What are you waiting for?
http://ads.sourceforge.net/cgi-bin/redirect.pl?micr5043en
[INVALID FOOTER]

Reply via email to