It's used internally right now, but the mechanism could be surfaced by
configurable controller factories.

On the other hand, since singleton controllers are passed the XML of
their configuration, you can always compose layers of decoration
yourself.

Jeff Schnitzer
[EMAIL PROTECTED]

> -----Original Message-----
> From: Roy Truelove [mailto:[EMAIL PROTECTED]]
> Sent: Friday, August 09, 2002 11:46 AM
> To: [EMAIL PROTECTED]
> Subject: Re: [Mav-user] Using "decorator" pattern on controllers
> 
> Actually I just found the ControllerWithParams class in the Javadoc
which
> is
> defined as a "a Decorator pattern, adding params defined for a
> controller".
> Are they any examples of how this is used?
> 
> -Roy
> 
> ----- Original Message -----
> From: "jim moore" <[EMAIL PROTECTED]>
> To: <[EMAIL PROTECTED]>
> Sent: Friday, August 09, 2002 12:23 PM
> Subject: Re: [Mav-user] Using "decorator" pattern on controllers
> 
> 
> > This shouldn't be too difficult. Just have your decorator implement
> > ControllerSingleton, then you will get an init method in which the
> > controller node from maverick.xml is passed in.
> >
> > If you had a controller node that looked like:
> >
> > <controller class="com.foo.bar.MyControllerDecorator">
> >     <decorated class="com.foo.bar.SomeExistingController">
> > </controller>
> >
> > Your decorator could hold an internal controller. When the
decorator's
> go
> > method was called, it could call go on the decorated controller,
read
> the
> > result and the model, and still do its own thing. This is actually
> similar
> > to what I just sent as the CompositeController.
> >
> > --jim
> >
> > ----- Original Message -----
> > From: "Roy Truelove" <[EMAIL PROTECTED]>
> > To: <[EMAIL PROTECTED]>
> > Sent: Friday, August 09, 2002 12:04 PM
> > Subject: [Mav-user] Using "decorator" pattern on controllers
> >
> >
> > > Hey all,
> > >
> > >     I'm looking into the feasablity of using the Decorator
pattern* to
> > > create Controllers.  In the friendbook example, each controller
> inherits
> > > from another controller which inherits from another controller,
each
> one
> > > adding a little functionality.  The problem with this is that you
> can't
> > pick
> > > and choose which controllers you want to use, you have to use
> extentions
> > of
> > > extentions.  This would certainly help with the composite view
issues
> that
> > > are being discussed, as well as securing controllers, etc.
> > >
> > > The problem is .. how can this be done while keeping Maverick
> backwards
> > > compatable *and* keeping configuration to a minimum?  Any ideas?
> Since
> > > controllers are instantiated using reflections and not explicitly,
is
> the
> > > Decorator pattern even possible?
> > >
> > > *Decorator pattern info :
> > >
>
http://www.javaworld.com/javaworld/jw-12-2001/jw-1214-designpatterns.htm
l
> > >
> > > -Roy
> > >
> > >
> > >
> > > -------------------------------------------------------
> > > This sf.net email is sponsored by:ThinkGeek
> > > Welcome to geek heaven.
> > > http://thinkgeek.com/sf
> > > _______________________________________________
> > > Mav-user mailing list
> > > [EMAIL PROTECTED]
> > > https://lists.sourceforge.net/lists/listinfo/mav-user
> > > Archives are available at http://www.mail-archive.com/
> >
> >
> >
> > -------------------------------------------------------
> > This sf.net email is sponsored by:ThinkGeek
> > Welcome to geek heaven.
> > http://thinkgeek.com/sf
> > _______________________________________________
> > Mav-user mailing list
> > [EMAIL PROTECTED]
> > https://lists.sourceforge.net/lists/listinfo/mav-user
> > Archives are available at http://www.mail-archive.com/
> 
> 
> 
> -------------------------------------------------------
> This sf.net email is sponsored by:ThinkGeek
> Welcome to geek heaven.
> http://thinkgeek.com/sf
> _______________________________________________
> Mav-user mailing list
> [EMAIL PROTECTED]
> https://lists.sourceforge.net/lists/listinfo/mav-user
> Archives are available at http://www.mail-archive.com/


-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Mav-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mav-user
Archives are available at http://www.mail-archive.com/

Reply via email to