I know this is the coldspring-dev forum not the coldspring help forum, but I am having trouble trying to do something that I feel should be easy to do. I want to use the cs framework to pass a reference of the csFactory to one of my services.

-services.xml
<bean id="BusinessUnit" class="BusinessUnit" singleton="true">
   <constructor-arg name="csFactory"><value>${csFactory}</value></constructor-arg>
</bean>


So that in my BusinessUnit Service I can do this as the init

   <cffunction name="init" access="public" output="false" returntype="BusinessUnit">
   <cfargument name="csFactory" type="WEB-INF.cftags.component" required="true" />
        <cfscript>
            variables.instance = structNew();
           
            setFactory( arguments.csFactory);
            setDGO(getFactory().getBean("BusinessUnitDGO"));
            return this;
        </cfscript>
     </cffunction>


I know that mach-ii does this in a weird way but this seems like something that you should be able to do with the basic functionality in cs.  Of couse I haven't spent much time with the framework, so I am probably just missing something simple.


Reply via email to