Zitat von Cosmin Bucur <[EMAIL PROTECTED]>:
> I have the following service :
>
> <contribution configuration-id="tapestry.services.ApplicationServices">
> <service name="reportService" object="service:ReportService" />
> </contribution>
>
> <service-point id="ReportService"
> interface="org.apache.tapestry.engine.IEngineService">
> <invoke-factory model="singleton">
> <construct class="view.report.ReportService" />
> </invoke-factory>
> </service-point>
>
> I would like to inject a spring bean into this service . I am
> currently able to inject spring beans into normal tapestry pages using
> : <inject property="manager" object="spring:programManager" /> in the
> .jwc/.page files . What is the standard way to do this in Tap4 with
> Services ? I can't seem to be able to find any examples or
> documentation on this matter .
Without testing, just hammerd into newsclient:
<service-point id="ReportService"
interface="org.apache.tapestry.engine.IEngineService">
<invoke-factory model="singleton">
<construct class="view.report.ReportService">
<set-object property="manager" value="spring:programManager"/>
</construc>
</invoke-factory>
</service-point>
Basically, you can set it via set-object, the spring prefix tells
Hivemind to use the Spring Factory for injection.
HTH
Regards,
Christian
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]