[jboss-osgi-issues] [JBoss JIRA] (JBOSGI-599) The system bundle only support very simple syntax for the system packages
Guillaume Nodet (JIRA)
jira-events at lists.jboss.org
Mon Sep 3 12:20:32 EDT 2012
[ https://issues.jboss.org/browse/JBOSGI-599?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12715460#comment-12715460 ]
Guillaume Nodet commented on JBOSGI-599:
----------------------------------------
A simple working solution:
{code}
private OSGiMetaData createOSGiMetaData() {
// Initialize the OSGiMetaData
OSGiMetaDataBuilder builder = OSGiMetaDataBuilder.createBuilder(Constants.SYSTEM_BUNDLE_SYMBOLICNAME, Version.emptyVersion);
SystemPathsPlugin systemPackages = injectedSystemPaths.getValue();
List<String> exportedPackages = new ArrayList<String>();
exportedPackages.addAll(systemPackages.getSystemPackages());
// Construct framework capabilities from system packages
for (String packageSpec : exportedPackages) {
int versionIndex = packageSpec.indexOf(";version=");
if (versionIndex <= 0) {
packageSpec += ";version=0.0.0";
}
builder.addExportPackages(packageSpec);
}
return builder.getOSGiMetaData();
}
{code}
> The system bundle only support very simple syntax for the system packages
> -------------------------------------------------------------------------
>
> Key: JBOSGI-599
> URL: https://issues.jboss.org/browse/JBOSGI-599
> Project: JBoss OSGi
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Reporter: Guillaume Nodet
> Assignee: Thomas Diesler
>
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jboss-osgi-issues
mailing list