public class CapabilityAdapter {
public static void adapt(BundleInfo bundleInfo, Capability capability) throws ParseException {
String name = capability.getName();
if (BundleInfo.PACKAGE_TYPE.equals(name)) {
ExportPackage exportPackage = getExportPackage(bundleInfo, capability);
bundleInfo.addCapability(exportPackage);
} else if (BundleInfo.BUNDLE_TYPE.equals(name)) {
// nothing to do, already handled at the resource tag level
} else if (BundleInfo.SERVICE_TYPE.equals(name)) {
BundleCapability service = getOSGiService(bundleInfo, capability);