hivemind-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Achim Huegen <achim.hue...@gmx.de>
Subject Re: services...
Date Thu, 12 Jan 2006 09:23:14 GMT
You won't be able to solve this problem simply by defining
service points in the right way, if you plan to use only
one implementation class.
I would suggest to implement two classes: InternalMyServiceImpl
and MyServiceImpl.
While InternalMyServiceImpl does all the work, MyServiceImpl just 
delegates all public method calls to
a instance of InternalMyServiceImpl which is injected
as dependency.

This will result in two service points. The InternalMyService
service point can be hidden from the outside by using 
visibility="private" attribute.

Achim


Norbert Sándor wrote:
> 
> Hello,
>  
> I have a service interface for public usage like
>  
> public interface MyService
> {
>     public void doSomething();
> }
>  
> and one for internal usage (inside my framework)
>  
> public interface InternalMyService extends Service
> {
>     public void soSomethingInternal();
> }
>  
> How should I define service point(s) in hivemodule.xml to allow:
> - my framework classes to access the service as InternalMyService
> - to force outside access as MyService
>  
> Thanks for your help!
> BR,
> Norbi

---------------------------------------------------------------------
To unsubscribe, e-mail: hivemind-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: hivemind-user-help@jakarta.apache.org


Mime
View raw message