Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[platform-core-dev] Question about initializing the new message catalogs

In the snippets given for initializing the Messages class, it calls a 
class in the OSGi layer, passing the message bundle name and the Messages 
class object, where these are in some higher-level plug-in.

import org.eclipse.osgi.util.NLS;
...
private static final String BUNDLE_NAME = 
"org.eclipse.core.utils.messages"; //$NON-NLS-1$
static {
   NLS.initializeMessages(BUNDLE_NAME, Messages.class);
}


How does the NLS class resolve the message bundle?  In traditional eclipse 
plug-in visibility rules, lower-level plug-ins can't see classes or 
resources from higher-level plug-ins.
Is this using the 'Import-Package: *' capability of OSGi?  I didn't see 
this in org.ecillpse.osgi's manifests.

Just curious as to how this works,
Nick



Back to the top