Package org.eclipse.osgi.container
Class ModuleWiring
java.lang.Object
org.eclipse.osgi.container.ModuleWiring
- All Implemented Interfaces:
BundleReference
,BundleWiring
,Wiring
An implementation of
BundleWiring
.- Since:
- 3.10
-
Field Summary
Fields inherited from interface org.osgi.framework.wiring.BundleWiring
FINDENTRIES_RECURSE, LISTRESOURCES_LOCAL, LISTRESOURCES_RECURSE
-
Method Summary
Modifier and TypeMethodDescriptionvoid
addDynamicImports
(ModuleRevisionBuilder builder) Adds therequirements
from the specified builder to this wiring.findEntries
(String path, String filePattern, int options) getCapabilities
(String namespace) getModuleCapabilities
(String namespace) Returns the same result asgetCapabilities(String)
except uses type ModuleCapability and the returned list is unmodifiable.Returns the module loader for this wiring.getModuleRequirements
(String namespace) Returns the same result asgetRequirements(String)
except uses type ModuleRequirement and the returned list is unmodifiable.getProvidedModuleWires
(String namespace) Returns the same result asgetProvidedWires(String)
except uses type ModuleWire and the returned list is unmodifiable.getProvidedResourceWires
(String namespace) getProvidedWires
(String namespace) getRequiredModuleWires
(String namespace) Returns the same result asgetRequiredWires(String)
except uses type ModuleWire and the returned list is unmodifiable.getRequiredResourceWires
(String namespace) getRequiredWires
(String namespace) getRequirements
(String namespace) getResourceCapabilities
(String namespace) getResourceRequirements
(String namespace) Returns an unmodifiable collection of package names for package capabilities that have been substituted.boolean
boolean
isInUse()
boolean
isSubstitutedPackage
(String packageName) Returns true if the specified package name has been substituted in this wiringlistResources
(String path, String filePattern, int options) toString()
-
Method Details
-
getBundle
- Specified by:
getBundle
in interfaceBundleReference
-
isCurrent
public boolean isCurrent()- Specified by:
isCurrent
in interfaceBundleWiring
-
isInUse
public boolean isInUse()- Specified by:
isInUse
in interfaceBundleWiring
-
getModuleCapabilities
Returns the same result asgetCapabilities(String)
except uses type ModuleCapability and the returned list is unmodifiable.- Parameters:
namespace
- the namespace- Returns:
- the capabilities
- See Also:
-
getModuleRequirements
Returns the same result asgetRequirements(String)
except uses type ModuleRequirement and the returned list is unmodifiable.- Parameters:
namespace
- the namespace- Returns:
- the requirements
- See Also:
-
getCapabilities
- Specified by:
getCapabilities
in interfaceBundleWiring
-
getRequirements
- Specified by:
getRequirements
in interfaceBundleWiring
-
getProvidedModuleWires
Returns the same result asgetProvidedWires(String)
except uses type ModuleWire and the returned list is unmodifiable.- Parameters:
namespace
- the namespace- Returns:
- the wires
- See Also:
-
getRequiredModuleWires
Returns the same result asgetRequiredWires(String)
except uses type ModuleWire and the returned list is unmodifiable.- Parameters:
namespace
- the namespace- Returns:
- the wires
- See Also:
-
getProvidedWires
- Specified by:
getProvidedWires
in interfaceBundleWiring
-
getRequiredWires
- Specified by:
getRequiredWires
in interfaceBundleWiring
-
getRevision
- Specified by:
getRevision
in interfaceBundleWiring
-
getClassLoader
- Specified by:
getClassLoader
in interfaceBundleWiring
-
getModuleLoader
Returns the module loader for this wiring. If the module loader does not exist yet then one will be created- Returns:
- the module loader for this wiring.
-
findEntries
- Specified by:
findEntries
in interfaceBundleWiring
-
listResources
- Specified by:
listResources
in interfaceBundleWiring
-
getResourceCapabilities
- Specified by:
getResourceCapabilities
in interfaceBundleWiring
- Specified by:
getResourceCapabilities
in interfaceWiring
-
getResourceRequirements
- Specified by:
getResourceRequirements
in interfaceBundleWiring
- Specified by:
getResourceRequirements
in interfaceWiring
-
getProvidedResourceWires
- Specified by:
getProvidedResourceWires
in interfaceBundleWiring
- Specified by:
getProvidedResourceWires
in interfaceWiring
-
getRequiredResourceWires
- Specified by:
getRequiredResourceWires
in interfaceBundleWiring
- Specified by:
getRequiredResourceWires
in interfaceWiring
-
getResource
- Specified by:
getResource
in interfaceBundleWiring
- Specified by:
getResource
in interfaceWiring
-
isSubstitutedPackage
Returns true if the specified package name has been substituted in this wiring- Parameters:
packageName
- the package name to check- Returns:
- true if the specified package name has been substituted in this wiring
-
getSubstitutedNames
Returns an unmodifiable collection of package names for package capabilities that have been substituted.- Returns:
- the substituted package names
-
addDynamicImports
Adds therequirements
from the specified builder to this wiring. The new requirements must be in thePackageNamespace
. These requirements are transient and will not exist when loading up persistent wirings.- Parameters:
builder
- the builder that defines the new dynamic imports.
-
toString
-