public class Bundles extends Object
| Constructor and Description |
|---|
Bundles() |
| Modifier and Type | Method and Description |
|---|---|
static Set<String> |
filterInstalled(org.osgi.framework.BundleContext bundleContext,
Collection<String> packages,
VersionResolver resolver)
Filter out any packages which are already installed as a version which matches the imported version range
|
static org.osgi.framework.Bundle |
findBundle(org.osgi.framework.BundleContext bundleContext,
String name,
String version) |
static Set<org.osgi.framework.Bundle> |
findBundles(org.osgi.framework.BundleContext context,
String name)
Find installed bundles by symbolic name
|
static org.osgi.framework.Bundle |
findOneBundle(org.osgi.framework.BundleContext context,
String name)
Find a single installed bundle by symbolic name.
|
static boolean |
isFragment(org.osgi.framework.Bundle bundle)
Returns true if the given bundle is a fragment (and so cannot be loaded)
|
static boolean |
isInstalled(org.osgi.framework.BundleContext bundleContext,
String name,
String version) |
public static boolean isInstalled(org.osgi.framework.BundleContext bundleContext,
String name,
String version)
public static Set<String> filterInstalled(org.osgi.framework.BundleContext bundleContext, Collection<String> packages, VersionResolver resolver)
public static org.osgi.framework.Bundle findBundle(org.osgi.framework.BundleContext bundleContext,
String name,
String version)
public static Set<org.osgi.framework.Bundle> findBundles(org.osgi.framework.BundleContext context, String name)
context - the bundle context to searchname - the bundle symbolic namepublic static org.osgi.framework.Bundle findOneBundle(org.osgi.framework.BundleContext context,
String name)
context - the bundle context to searchname - the bundle symbolic nameIllegalStateException - if there are no matching bundles or more than one matching bundlepublic static boolean isFragment(org.osgi.framework.Bundle bundle)
Copyright © 2011–2014 Red Hat. All rights reserved.