Hello there! I've got Hall's book, and even after reading section 2.4.3
where he explains why would one need to import and export a package I'm
still a bit confused.

A good explanation provided by him was " (...)common situation when
importing and exporting is useful is
when using an interface-based development approach. (...)" Well, this is
just my case :)

We are building an open source governance tool (we already have the product
on a locked non osgi architecture, we are just migrating and opening it to
the community), well we have several parsers (Java, COBOL, C#, C++, PHP ...)
and we would like to have our parsers to be implemented as bundles. So I
guess I'll have an interface: org.openspotlight.parsers.Parser which each
bundle must implement, so let's suppose I have two bundles (java and cobol)
I would export this packages:

Export-Package: org.openspotlight.parsers.java
.
.
.
Export-Package: org.openspotlight.parsers.cobol


Why would I need to add an import-package statement to my manifest as well?
Would it be a problem if I do not? Also We intend to use the parsers as
services, so on each bundle we add an activator to register the given
implementation using the general interface, I guess this is ok as well
right?

Best regards

Reply via email to