Author: rickhall
Date: Tue Apr 19 14:16:59 2011
New Revision: 1095097
URL: http://svn.apache.org/viewvc?rev=1095097&view=rev
Log:
Replaced Module with BundleRevision.
Added:
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/BundleRevisionImpl.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/HostBundleRevision.java
- copied, changed from r1091796,
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/HostModule.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/ResolverWire.java
- copied, changed from r1091796,
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/Wire.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/ResolverWireImpl.java
- copied, changed from r1091796,
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/WireImpl.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/wiring/FelixBundleWire.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/wiring/FelixBundleWireImpl.java
- copied, changed from r1091796,
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/WireImpl.java
Removed:
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/ModuleImpl.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/HostModule.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/Module.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/Wire.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/WireImpl.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/WireModuleImpl.java
Modified:
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/BundleImpl.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/BundleProtectionDomain.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/EntryFilterEnumeration.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/ExportedPackageImpl.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/ExtensionManager.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/Felix.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/FilterImpl.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/PackageAdminImpl.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/RequiredBundleImpl.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/ResolverStateImpl.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/ServiceRegistrationImpl.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/ServiceRegistry.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/URLHandlersBundleStreamHandler.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/URLHandlersBundleURLConnection.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/capabilityset/CapabilitySet.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/CandidateComparator.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/Candidates.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/HostedCapability.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/HostedRequirement.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/ResolveException.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/Resolver.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/resolver/ResolverImpl.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/util/Util.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/util/manifestparser/ManifestParser.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/wiring/BundleCapabilityImpl.java
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/wiring/BundleRequirementImpl.java
Modified:
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/BundleImpl.java
URL:
http://svn.apache.org/viewvc/felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/BundleImpl.java?rev=1095097&r1=1095096&r2=1095097&view=diff
==============================================================================
---
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/BundleImpl.java
(original)
+++
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/BundleImpl.java
Tue Apr 19 14:16:59 2011
@@ -18,6 +18,7 @@
*/
package org.apache.felix.framework;
+import com.sun.xml.internal.ws.api.server.Module;
import java.io.IOException;
import java.io.InputStream;
import java.net.URL;
@@ -25,12 +26,12 @@ import java.security.ProtectionDomain;
import java.util.*;
import org.apache.felix.framework.cache.BundleArchive;
-import org.apache.felix.framework.resolver.Module;
import org.apache.felix.framework.ext.SecurityProvider;
-import org.apache.felix.framework.resolver.Wire;
import org.apache.felix.framework.util.StringMap;
import org.apache.felix.framework.util.Util;
+import org.apache.felix.framework.wiring.FelixBundleWire;
import org.osgi.framework.*;
+import org.osgi.framework.wiring.BundleRevision;
class BundleImpl implements Bundle
{
@@ -38,7 +39,7 @@ class BundleImpl implements Bundle
private final Felix __m_felix;
private final BundleArchive m_archive;
- private final List<Module> m_modules = new ArrayList<Module>(0);
+ private final List<BundleRevision> m_revisions = new
ArrayList<BundleRevision>(0);
private volatile int m_state;
private boolean m_useDeclaredActivationPolicy;
private BundleActivator m_activator = null;
@@ -78,8 +79,8 @@ class BundleImpl implements Bundle
m_activator = null;
m_context = null;
- Module module = createModule();
- addModule(module);
+ BundleRevision revision = createRevision();
+ addRevision(revision);
}
// This method exists because the system bundle extends BundleImpl
@@ -98,7 +99,7 @@ class BundleImpl implements Bundle
synchronized void close()
{
- closeModules();
+ closeRevisions();
try
{
m_archive.close();
@@ -116,38 +117,38 @@ class BundleImpl implements Bundle
{
// Mark the bundle as stale, since it is being deleted.
m_stale = true;
- // Close all modules.
- closeModules();
+ // Close all revisions.
+ closeRevisions();
// Delete bundle archive, which will close revisions.
m_archive.closeAndDelete();
}
- private void closeModules()
+ private void closeRevisions()
{
- // Remove the bundle's associated modules from the resolver state
+ // Remove the bundle's associated revisions from the resolver state
// and close them.
- for (Module m : m_modules)
+ for (BundleRevision br : m_revisions)
{
- // Remove the module from the resolver state.
- getFramework().getResolver().removeModule(m);
+ // Remove the revision from the resolver state.
+ getFramework().getResolver().removeRevision(br);
- // Set fragments to null, which will remove the module from all
- // of its dependent fragment modules.
+ // Set fragments to null, which will remove the revision from all
+ // of its dependent fragment revisions.
try
{
- ((ModuleImpl) m).attachFragments(null);
+ ((BundleRevisionImpl) br).attachFragments(null);
}
catch (Exception ex)
{
getFramework().getLogger().log(
- m.getBundle(), Logger.LOG_ERROR, "Error detaching
fragments.", ex);
+ br.getBundle(), Logger.LOG_ERROR, "Error detaching
fragments.", ex);
}
- // Set wires to null, which will remove the module from all
- // of its dependent modules.
- ((ModuleImpl) m).setWires(null);
+ // Set wires to null, which will remove the revision from all
+ // of its dependent revisions.
+ ((BundleRevisionImpl) br).setWires(null);
- // Close the module's content.
- ((ModuleImpl) m).close();
+ // Close the revision's content.
+ ((BundleRevisionImpl) br).close();
}
}
@@ -160,17 +161,17 @@ class BundleImpl implements Bundle
}
else
{
- // Dispose of the current modules.
- closeModules();
+ // Dispose of the current revisions.
+ closeRevisions();
// Now we will purge all old revisions, only keeping the newest
one.
m_archive.purge();
// Lastly, we want to reset our bundle be reinitializing our state
- // and recreating a module for the newest revision.
- m_modules.clear();
- final Module module = createModule();
- addModule(module);
+ // and recreating a revision object for the newest revision.
+ m_revisions.clear();
+ final BundleRevision br = createRevision();
+ addRevision(br);
m_state = Bundle.INSTALLED;
m_stale = false;
m_cachedHeaders.clear();
@@ -323,7 +324,8 @@ class BundleImpl implements Bundle
// Spec says empty local returns raw headers.
if (locale.length() == 0)
{
- result = new StringMap(getCurrentModule().getHeaders(), false);
+ result = new StringMap(
+ ((BundleRevisionImpl) getCurrentRevision()).getHeaders(),
false);
}
// If we have no result, try to get it from the cached headers.
@@ -359,7 +361,8 @@ class BundleImpl implements Bundle
if (result == null)
{
// Get a modifiable copy of the raw headers.
- Map headers = new StringMap(getCurrentModule().getHeaders(),
false);
+ Map headers = new StringMap(
+ ((BundleRevisionImpl) getCurrentRevision()).getHeaders(),
false);
// Assume for now that this will be the result.
result = headers;
@@ -388,23 +391,22 @@ class BundleImpl implements Bundle
basename = Constants.BUNDLE_LOCALIZATION_DEFAULT_BASENAME;
}
- // Create ordered list of modules to search for localization
+ // Create ordered list of revisions to search for localization
// property resources.
- List moduleList = createLocalizationModuleList(
- (ModuleImpl) getCurrentModule());
+ List<BundleRevision> revisionList =
createLocalizationRevisionList(
+ (BundleRevisionImpl) getCurrentRevision());
// Create ordered list of files to load properties from
- List resourceList = createLocalizationResourceList(basename,
locale);
+ List<String> resourceList =
createLocalizationResourceList(basename, locale);
// Create a merged props file with all available props for
this locale
boolean found = false;
Properties mergedProperties = new Properties();
- for (int modIdx = 0; modIdx < moduleList.size(); modIdx++)
+ for (BundleRevision br : revisionList)
{
- for (Iterator it = resourceList.iterator(); it.hasNext(); )
+ for (String res : resourceList)
{
- URL temp = ((Module) moduleList.get(modIdx)).getEntry(
- it.next() + ".properties");
+ URL temp = ((BundleRevisionImpl) br).getEntry(res +
".properties");
if (temp != null)
{
found = true;
@@ -466,36 +468,38 @@ class BundleImpl implements Bundle
}
}
- private static List createLocalizationModuleList(ModuleImpl module)
+ private static List<BundleRevision> createLocalizationRevisionList(
+ BundleRevisionImpl bri)
{
- // If the module is a fragment, then we actually need
+ // If the revision is a fragment, then we actually need
// to search its host and associated fragments for its
// localization information. So, check to see if there
// are any hosts and then use the one with the highest
// version instead of the fragment itself. If there are
- // no hosts, but the module is a fragment, then just
- // search the module itself.
- if (Util.isFragment(module))
+ // no hosts, but the revision is a fragment, then just
+ // search the revision itself.
+ if (Util.isFragment(bri))
{
- List<Wire> hostWires = module.getWires();
+ List<FelixBundleWire> hostWires = bri.getWires();
if ((hostWires != null) && (hostWires.size() > 0))
{
- module = (ModuleImpl) hostWires.get(0).getExporter();
+ bri = (BundleRevisionImpl)
hostWires.get(0).getProviderWiring().getRevision();
for (int hostIdx = 1; hostIdx < hostWires.size(); hostIdx++)
{
- if (module.getVersion().compareTo(
- hostWires.get(hostIdx).getExporter().getVersion()) < 0)
+ if (bri.getVersion().compareTo(
+
hostWires.get(hostIdx).getProviderWiring().getRevision().getVersion()) < 0)
{
- module = (ModuleImpl)
hostWires.get(hostIdx).getExporter();
+ bri = (BundleRevisionImpl)
+
hostWires.get(hostIdx).getProviderWiring().getRevision();
}
}
}
}
- // Create a list of the module and any attached fragments.
- List result = new ArrayList();
- result.add(module);
- List<Module> fragments = module.getFragments();
+ // Create a list of the revision and any attached fragment revisions.
+ List<BundleRevision> result = new ArrayList<BundleRevision>();
+ result.add(bri);
+ List<BundleRevision> fragments = bri.getFragments();
if (fragments != null)
{
result.addAll(fragments);
@@ -503,9 +507,9 @@ class BundleImpl implements Bundle
return result;
}
- private static List createLocalizationResourceList(String basename, String
locale)
+ private static List<String> createLocalizationResourceList(String
basename, String locale)
{
- List result = new ArrayList(4);
+ List<String> result = new ArrayList(4);
StringTokenizer tokens;
StringBuffer tempLocale = new StringBuffer(basename);
@@ -853,9 +857,9 @@ class BundleImpl implements Bundle
synchronized boolean isExtension()
{
- for (int i = (m_modules.size() - 1); i > -1; i--)
+ for (int i = (m_revisions.size() - 1); i > -1; i--)
{
- if (m_modules.get(i).isExtension())
+ if (((BundleRevisionImpl) m_revisions.get(i)).isExtension())
{
return true;
}
@@ -865,12 +869,12 @@ class BundleImpl implements Bundle
public String getSymbolicName()
{
- return getCurrentModule().getSymbolicName();
+ return getCurrentRevision().getSymbolicName();
}
public Version getVersion()
{
- return getCurrentModule().getVersion();
+ return getCurrentRevision().getVersion();
}
public boolean hasPermission(Object obj)
@@ -997,7 +1001,7 @@ class BundleImpl implements Bundle
public String toString()
{
- String sym = getCurrentModule().getSymbolicName();
+ String sym = getCurrentRevision().getSymbolicName();
if (sym != null)
{
return sym + " [" + getBundleId() +"]";
@@ -1007,11 +1011,11 @@ class BundleImpl implements Bundle
synchronized boolean isRemovalPending()
{
- return (m_state == Bundle.UNINSTALLED) || (m_modules.size() > 1) ||
m_stale;
+ return (m_state == Bundle.UNINSTALLED) || (m_revisions.size() > 1) ||
m_stale;
}
//
- // Module management.
+ // Revision management.
//
/**
@@ -1026,22 +1030,22 @@ class BundleImpl implements Bundle
* no limit on the potential number of bundle JAR file revisions.
* @return array of modules corresponding to the bundle JAR file revisions.
**/
- synchronized List<Module> getModules()
+ synchronized List<BundleRevision> getRevisions()
{
- return m_modules;
+ return m_revisions;
}
/**
* Determines if the specified module is associated with this bundle.
- * @param module the module to determine if it is associate with this
bundle.
+ * @param revision the module to determine if it is associate with this
bundle.
* @return <tt>true</tt> if the specified module is in the array of modules
* associated with this bundle, <tt>false</tt> otherwise.
**/
- synchronized boolean hasModule(Module module)
+ synchronized boolean hasRevision(BundleRevision revision)
{
- for (int i = 0; i < m_modules.size(); i++)
+ for (int i = 0; i < m_revisions.size(); i++)
{
- if (m_modules.get(i) == module)
+ if (m_revisions.get(i) == revision)
{
return true;
}
@@ -1054,28 +1058,29 @@ class BundleImpl implements Bundle
* in the module array.
* @return the newest module.
**/
- synchronized Module getCurrentModule()
+ synchronized BundleRevision getCurrentRevision()
{
- return m_modules.get(m_modules.size() - 1);
+ return m_revisions.get(m_revisions.size() - 1);
}
synchronized boolean isUsed()
{
boolean unresolved = true;
- for (int i = 0; unresolved && (i < m_modules.size()); i++)
+ for (int i = 0; unresolved && (i < m_revisions.size()); i++)
{
- if (m_modules.get(i).isResolved())
+ if (m_revisions.get(i).getWiring() != null)
{
unresolved = false;
}
}
boolean used = false;
- for (int i = 0; !unresolved && !used && (i < m_modules.size()); i++)
+ for (int i = 0; !unresolved && !used && (i < m_revisions.size()); i++)
{
- List<Module> dependents = ((ModuleImpl)
m_modules.get(i)).getDependents();
+ List<BundleRevision> dependents =
+ ((BundleRevisionImpl) m_revisions.get(i)).getDependents();
for (int j = 0; (dependents != null) && (j < dependents.size()) &&
!used; j++)
{
- if (dependents.get(j) != m_modules.get(i))
+ if (dependents.get(j) != m_revisions.get(i))
{
used = true;
}
@@ -1091,8 +1096,8 @@ class BundleImpl implements Bundle
m_archive.revise(location, is);
try
{
- Module module = createModule();
- addModule(module);
+ BundleRevision revision = createRevision();
+ addRevision(revision);
}
catch (Exception ex)
{
@@ -1104,27 +1109,27 @@ class BundleImpl implements Bundle
synchronized boolean rollbackRevise() throws Exception
{
boolean isExtension = isExtension();
- Module m = m_modules.remove(m_modules.size() - 1);
+ BundleRevision br = m_revisions.remove(m_revisions.size() - 1);
if (!isExtension)
{
- // Since revising a module adds the module to the global
+ // Since revising a bundle adds a revision to the global
// state, we must remove it from the global state on rollback.
- getFramework().getResolver().removeModule(m);
+ getFramework().getResolver().removeRevision(br);
}
return m_archive.rollbackRevise();
}
// This method should be private, but is visible because the
- // system bundle needs to add its module directly to the bundle,
- // since it doesn't have an archive from which the module will
- // be created, which is the normal case.
- synchronized void addModule(Module module) throws Exception
- {
- m_modules.add(module);
-
- // Set protection domain after adding the module to the bundle,
- // since this requires that the bundle has a module.
- ((ModuleImpl) module).setSecurityContext(
+ // system bundle needs to add its revision directly to the bundle,
+ // since it doesn't have an archive from which it will be created,
+ // which is the normal case.
+ synchronized void addRevision(BundleRevision revision) throws Exception
+ {
+ m_revisions.add(revision);
+
+ // Set protection domain after adding the revision to the bundle,
+ // since this requires that the bundle has a revision.
+ ((BundleRevisionImpl) revision).setSecurityContext(
new BundleProtectionDomain(getFramework(), this));
SecurityProvider sp = getFramework().getSecurityProvider();
@@ -1136,30 +1141,29 @@ class BundleImpl implements Bundle
}
catch (Exception ex)
{
- m_modules.remove(m_modules.size() - 1);
+ m_revisions.remove(m_revisions.size() - 1);
throw ex;
}
}
- // TODO: REFACTOR - consider moving ModuleImpl into the framework
package
- // so we can null module capabilities for extension bundles so we don't
- // need this check anymore.
+ // TODO: REFACTOR - consider nulling capabilities for extension bundles
+ // so we don't need this check anymore.
if (!isExtension())
{
- // Now that the module is added to the bundle, we can update
- // the resolver's module state.
- getFramework().getResolver().addModule(module);
+ // Now that the revision is added to the bundle, we can update
+ // the resolver's state to be aware of any new capabilities.
+ getFramework().getResolver().addRevision(revision);
}
}
- private Module createModule() throws Exception
+ private BundleRevision createRevision() throws Exception
{
- // Get and parse the manifest from the most recent revision to
- // create an associated module for it.
+ // Get and parse the manifest from the most recent revision and
+ // create an associated revision object for it.
Map headerMap = m_archive.getCurrentRevision().getManifestHeader();
- // Create the module instance.
- ModuleImpl module = new ModuleImpl(
+ // Create the bundle revision instance.
+ BundleRevisionImpl revision = new BundleRevisionImpl(
getFramework().getLogger(),
getFramework().getConfig(),
getFramework().getResolver(),
@@ -1173,11 +1177,11 @@ class BundleImpl implements Bundle
getFramework().getBootPackageWildcards());
// Verify that the bundle symbolic name + version is unique.
- if (module.getManifestVersion().equals("2"))
+ if (revision.getManifestVersion().equals("2"))
{
- Version bundleVersion = module.getVersion();
+ Version bundleVersion = revision.getVersion();
bundleVersion = (bundleVersion == null) ? Version.emptyVersion :
bundleVersion;
- String symName = module.getSymbolicName();
+ String symName = revision.getSymbolicName();
Bundle[] bundles = getFramework().getBundles();
for (int i = 0; (bundles != null) && (i < bundles.length); i++)
@@ -1186,8 +1190,8 @@ class BundleImpl implements Bundle
if (id != getBundleId())
{
String sym = bundles[i].getSymbolicName();
- Version ver = ((ModuleImpl)
- ((BundleImpl)
bundles[i]).getCurrentModule()).getVersion();
+ Version ver = ((BundleRevisionImpl)
+ ((BundleImpl)
bundles[i]).getCurrentRevision()).getVersion();
if ((symName != null) && (sym != null) &&
symName.equals(sym) && bundleVersion.equals(ver))
{
throw new BundleException(
@@ -1198,16 +1202,17 @@ class BundleImpl implements Bundle
}
}
- return module;
+ return revision;
}
synchronized ProtectionDomain getProtectionDomain()
{
ProtectionDomain pd = null;
- for (int i = m_modules.size() - 1; (i >= 0) && (pd == null); i--)
+ for (int i = m_revisions.size() - 1; (i >= 0) && (pd == null); i--)
{
- pd = (ProtectionDomain) m_modules.get(i).getSecurityContext();
+ pd = (ProtectionDomain)
+ ((BundleRevisionImpl) m_revisions.get(i)).getSecurityContext();
}
return pd;
@@ -1258,4 +1263,4 @@ class BundleImpl implements Bundle
{
return m_context;
}
-}
+}
\ No newline at end of file
Modified:
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/BundleProtectionDomain.java
URL:
http://svn.apache.org/viewvc/felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/BundleProtectionDomain.java?rev=1095097&r1=1095096&r2=1095097&view=diff
==============================================================================
---
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/BundleProtectionDomain.java
(original)
+++
felix/sandbox/rickhall/framework-r43/src/main/java/org/apache/felix/framework/BundleProtectionDomain.java
Tue Apr 19 14:16:59 2011
@@ -25,7 +25,7 @@ import java.security.Permission;
import java.security.ProtectionDomain;
import java.security.cert.Certificate;
-import org.apache.felix.framework.resolver.Module;
+import org.osgi.framework.wiring.BundleRevision;
public class BundleProtectionDomain extends ProtectionDomain
{
@@ -33,9 +33,9 @@ public class BundleProtectionDomain exte
private final WeakReference m_bundle;
private final int m_hashCode;
private final String m_toString;
- private final WeakReference m_module;
+ private final WeakReference m_revision;
- // TODO: SECURITY - This should probably take a module, not a bundle.
+ // TODO: SECURITY - This should probably take a revision, not a bundle.
BundleProtectionDomain(Felix felix, BundleImpl bundle)
throws MalformedURLException
{
@@ -50,14 +50,14 @@ public class BundleProtectionDomain exte
null);
m_felix = new WeakReference(felix);
m_bundle = new WeakReference(bundle);
- m_module = new WeakReference(bundle.getCurrentModule());
+ m_revision = new WeakReference(bundle.getCurrentRevision());
m_hashCode = bundle.hashCode();
m_toString = "[" + bundle + "]";
}
- Module getModule()
+ BundleRevision getRevision()
{
- return (Module) m_module.get();
+ return (BundleRevision) m_revision.get();
}
public boolean implies(Permission permission)