just injecting messages didn't work when i tried it.

Caused by: java.lang.RuntimeException: No service implements the interface org.apache.tapestry5.ioc.Messages. at org.apache.tapestry5.ioc.internal.RegistryImpl.getService(RegistryImpl.java:560) at org.apache.tapestry5.ioc.internal.ObjectLocatorImpl.getService(ObjectLocatorImpl.java:44) at org.apache.tapestry5.ioc.internal.services.MasterObjectProviderImpl$1.invoke(MasterObjectProviderImpl.java:56) at org.apache.tapestry5.ioc.internal.OperationTrackerImpl.invoke(OperationTrackerImpl.java:68)

FYI i'm using 5.1.0.5

Maybe a 'service' isn't what I'm after, but there MUST be a way to do this. Similar to how ComponentResources is configured.

Regards, Paul.

On 24/08/2011 11:31 PM, Steve Eynon wrote:
Hi,

If you just want messages for your service (as in messages defined in
MyService.properties) then, as nillihammer suggests, simply inject a
Messages object.

This is because Messages is actually an
org.apache.tapestry5.ioc.Messages and is defined and utilised by the
IOC layer. I believe Tapestry-Core extends the principle and provides
a chain of message objects beginning with the one defined for the
current Component / Page.

For which object do you need messages for?

Steve.
--
Steve Eynon
mobie: 0750 424 5743



On 24 August 2011 19:53, nillehammer<tapestry.nilleham...@winfonet.eu>  wrote:
The easiest way is to define your service methods with an additional Messages
parameter. This way you can use the Messages within the service methods.

-----
http://www.winfonet.eu
--
View this message in context: 
http://tapestry.1045711.n5.nabble.com/component-scope-service-with-injected-messages-tp4724993p4730146.html
Sent from the Tapestry - User mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org

Reply via email to