On Wed, Mar 28, 2012 at 6:09 PM, Crentana <i...@crentana.de> wrote:
> While trying to write a customized version of SecurityService
> (tapestry-security) I encountered a problem, which Im unable to solve
> Target:
> Writing a customized Version of SecurityService which supports the original
> methods as well as new ones.
> but I cant figure out how to bind it.
> Main problem is the existing SecurityService binding in the SecurityModule
> which causes the Error about two services implementing the same interface

Without a doubt, your approach is wrong. A service is a service and it
is interface-based. You can override the implementation but you cannot
change the interface of an existing service. If you need getUser(),
implement UserService.getUser() and use that service in your
overridden SecurityService implementation. In other words, think
composition not inheritance. For how to override services, see
http://tapestry.apache.org/ioc-cookbook-overriding-ioc-services.html.

Kalle

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

Reply via email to