Beans have nothing to do with services, but are just a nice method to
define member-like objects in components/pages -
you do mean <bean ...> in the .jwc/.page, do you?
ציטוט John Coleman:
Thanks for that Ron, seems quite clear. But it leaves me wondering what the
bean factory locator is for?
John
----- Original Message -----
From: "Ron Piterman" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Monday, November 14, 2005 8:01 PM
Subject: Re: hivemind tutorial for tapestry user
you add a hivemodule.xml either in
/META-INF
or in
<context>/WEB-INF/
or in
<context>/WEB-INF/<app-name>/
You use the syntax:
<?xml ...?>
<module id="moduleid" version ="1.0.0" package="package.name">
<service-point id="ServiceId"
interface="interface.name.relative.to.package.or.absolute">
<invoke-factory>
<construct
class="implementation.class.name.relative.to.package.or.absolute"/>
</invoke-factory>
</service-point>
</module>
alternativley, you can seprate service-point as an empty element, and
add the invoke-factory element in an
<implementation service-id="ServiceId">
<invoke-factory...
</implementation>
From tapestry you inject the object as
<inject object="service:moduleid.ServiceId"/>
or
@InjectObject("service:...")
public abstract getServiceXXX();
if you need another model than the singleton, you set it on the
invoke-factory element.
Cheers,
Ron
ציטוט hv @ Fashion Content:
Anyone know of a good hivemind tutorial with a tapestry perspective. The
info I have found on the Hivemind site seems very confusing and quite
different from Tapestry 4 config.
Just looking for how to create singleton beans for use with my tapestry
pages.
Henrik
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]