Declarative Services re-use implementation class [message #991640] |
Wed, 19 December 2012 22:35 |
Johan Van Noten Messages: 87 Registered: July 2009 |
Member |
|
|
Today we were reviewing a project that extensively uses declarative services.
We noticed that several component definitions were pointing to the same implementation class.
For instance:
* BundleA defines and exports a class AImpl with interface A.
* BundleB1
- imports AImpl's package
- defines a component C1 with implementation class AImpl and registers service A.
* BundleB2
- imports AImpl's package
- defines a component C2 with implementation class AImpl and registers service A.
Other bundles select the desired services by filtering on the registration properties of A from B1 and B2.
Question:
Re-using this same implementation class seemed odd to us.
Is there any real objection against using the same implementation class for multiple components?
The spec doesn't say anything about it afaik.
Does the Equinox implementation have any issues with it?
Thanks,
Johan
[Updated on: Wed, 19 December 2012 22:36] Report message to a moderator
|
|
|
|
Powered by
FUDForum. Page generated in 0.01904 seconds