I'd like to create a ResponderCommandFactory in the context, e.g.
The issue is that the <array> XML results in an array of strings, and not an array of classes, as the function expects.Code:<object id="aCommandFactory" class="org.springextensions.actionscript.cairngorm.commands.ResponderCommandFactory" scope="protoype"> <method-invocation name="addBusinessDelegateFactory"> <arg> <ref>aDelegateFactory</ref> </arg> <arg> <array> <value>com.example.Command1</value> <value>com.example.Command2</value> </array> </arg> </method-invocation> </object>
Is there (concise) context XML syntax that would configure an array of classes?
It looks like there isn't and the work-around for configuring a ResponderCommandFactory is to extend the Spring Cairngorm AS class with a custom class, and adding a method that accepts an array of strings, converting it into an array of classes.
Should the ResponderCommandFactory provide such a method?
In contrast, an object property value is conveniently type-converted into a Class if the object property is typed as Class, e.g.
Thoughts?Code:<object id="aDelegateFactory" class="org.springextensions.actionscript.cairngorm.business.BusinessDelegateFactory" scope="protoype"> <property name="delegateClass" value="com.example.Delegate"/> </object>


Reply With Quote