Hmm...I like the idea of combining the configurations from a maintenance point of view, but on the other hand, the flow chain can get lost, particularly when the number of commands are in a minority. Separating also has the benefit, in our case anyways, of having the chain stay generic, but Spring providing implementations specific to an environment.

Still, one less file is always a good thing as well. I wonder what it would look like if you customized the XML file format a bit. Didn't James Strachan do something like that with one of his projects?

Don

Ted Husted wrote:
On 8/31/05, Don Brown <[EMAIL PROTECTED]> wrote:

You might also be interested in the Spring and Chain integration piece I wrote for Ti.



We just load the Commands and Chains with Spring, along with everything else, and don't bother with a separate catalog. It started out ugly, but if you make good use of the parent features, things end up pretty clean, and there's only one DI syntax. <object id="BaseChain" type="WQD.Core.Commands.BaseChain, WQD.Core" parent="BaseLogic"/>

... later ...
<object id="facility_edit" parent="BaseChain">
<property name="AddCommands">
<list>
<ref object="facility_select" />
<ref object="facility_find" />
</list>
</property>
</object>

We had to extend the original CoR API a bit, so that we could add a list of commands to a chian. This is from a C# application, but you see what is happening. We also do things like create base data-access commands that know how to run iBATIS
-Ted.



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

Reply via email to