On 6/6/13 11:09 AM, Carsten Ziegeler wrote:
2013/6/6 Agemo Cui <[email protected]>
On 6/6/13 5:21 AM, Chetan Mehrotra wrote:
I have at times also struggled with DS when I moved from Blueprint. Within
a Bundle if there are some internal services which are used by various DS
Components *within* that bundle then is it fine to
1. Register these internal services as DS components but with classes
which
are not part of Export-Package list i.e. private classes
Yes (at least) for Apache SCR.
Do you mean, this doesn't or might not work with other DS implementations?
Yes. Because Im not sure if this is mentioned in the spec.
However, it works in my case using felix scr.
But other bundles are not really prevented from using this service by this
method.
The service still can be fetched, and be used through reflection.
I don't think this is a problem - you can do all kinds of tricks using
reflection etc.
However, I'm not sure if you're really able to get the service as
ServiceReference.isAssignableTo is called and if I understand this
correctly, this will fail as the client bundle does not see the private
class under which the service is registered.
Sorry, it's not a problem
Carsten
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]