commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Manfred Wolff <>
Subject Re: [chain] how to delegate to a command?
Date Mon, 12 Jul 2004 18:27:01 GMT


Hmmm. I think the "chain of responsibility" pattern is not made to 
configure the chains on the fly ;-). If you have a decision configure 
all chains that are envolved and let the commands  themself decide if 
they can fulfill the business logic or not.

If a command aaa has the desision to go either to command bbb or to 
command ccc configure both.

  <chain name="single">
      <command className=""/>
      <command className="org.strutsit.chain.bbb"/>
      <command className="org.strutsit.chain.ccc"/>

Either command aaa can fill the context with the information which 
command has to follow (context.put("next", "ccc")); or the following 
command themself has the responsibility to fulfill the request, or not.


Vic Cekvenich wrote:

> I want to from one command create another command to go to?
> How?
> Right now I place the catalog in the context and then use that.
> Is there a better way?
> tia,
> .V
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message