public Bundle getBundle(String symbolicName) {
if (isStale()) {
throw new IllegalStateException("Can not get bundle from stale deployment package.");
}
BundleInfo bundleInfo = (BundleInfo) m_nameToBundleInfo.get(symbolicName);
if (bundleInfo != null) {
Version version = bundleInfo.getVersion();
Bundle[] bundles = m_bundleContext.getBundles();
for (int i = 0; i < bundles.length; i++) {
if (symbolicName.equals(bundles[i].getSymbolicName()) && version.equals(bundles[i].getVersion())) {
return bundles[i];