Package org.osgi.service.clusterinfo
Interface FrameworkManager
- All Known Subinterfaces:
FrameworkNodeStatus
public interface FrameworkManager
Provides a management interface for accessing and managing a remote OSGi
framework. This interface can be accessed remotely via Remote Services.
-
Method Summary
Modifier and TypeMethodDescriptiongetBundle
(long id) Retrieve the bundle representation for a given bundle Id.getBundleHeaders
(long id) Get the header for a bundle given by its bundle Id.Get the bundle representations for all bundles currently installed in the managed framework.getBundleStartLevel
(long id) Get the start level for a bundle given by its bundle Id.int
getBundleState
(long id) Get the state for a given bundle Id.Retrieves the current framework start level.getServiceReference
(long id) Get the service representation for a service given by its service Id.Get the service representations for all services.getServiceReferences
(String filter) Get the service representations for all services.installBundle
(String location) Install a new bundle given by an externally reachable location string, typically describing a URL.void
setBundleStartLevel
(long id, int startLevel) Set the start level for a bundle given by its bundle Id.void
setFrameworkStartLevel
(FrameworkStartLevelDTO startLevel) Sets the current framework start level.void
startBundle
(long id) Start a bundle given by its bundle Id.void
startBundle
(long id, int options) Start a bundle given by its bundle Id.void
stopBundle
(long id) Stop a bundle given by its bundle Id.void
stopBundle
(long id, int options) Stop a bundle given by its bundle Id.uninstallBundle
(long id) Uninstall a bundle given by its bundle Id.updateBundle
(long id) Updates a bundle given by its bundle Id using the bundle-internal update location.updateBundle
(long id, String url) Updates a bundle given by its URI path using the content at the specified URL.
-
Method Details
-
getBundle
Retrieve the bundle representation for a given bundle Id. -
getBundleHeaders
Get the header for a bundle given by its bundle Id.- Parameters:
id
- Addresses the bundle by its identifier.- Returns:
- Returns the map of headers entries.
- Throws:
Exception
- An exception representing a failure in the underlying remote call.
-
getBundles
Get the bundle representations for all bundles currently installed in the managed framework.- Returns:
- Returns a collection of BundleDTO objects.
- Throws:
Exception
- An exception representing a failure in the underlying remote call.
-
getBundleStartLevel
Get the start level for a bundle given by its bundle Id.- Parameters:
id
- Addresses the bundle by its identifier.- Returns:
- Returns a
BundleStartLevelDTO
describing the current start level of the bundle. - Throws:
Exception
- An exception representing a failure in the underlying remote call.
-
getBundleState
Get the state for a given bundle Id. -
getFrameworkStartLevel
Retrieves the current framework start level.- Returns:
- Returns the current framework start level in the form of a
FrameworkStartLevelDTO
. - Throws:
Exception
- An exception representing a failure in the underlying remote call.
-
getServiceReference
Get the service representation for a service given by its service Id.- Parameters:
id
- Addresses the service by its identifier.- Returns:
- The service representation as
ServiceReferenceDTO
. - Throws:
Exception
- An exception representing a failure in the underlying remote call.
-
getServiceReferences
Get the service representations for all services.- Returns:
- Returns the service representations in the form of
ServiceReferenceDTO
objects. - Throws:
Exception
- An exception representing a failure in the underlying remote call.
-
getServiceReferences
Get the service representations for all services.- Parameters:
filter
- Passes a filter to restrict the result set.- Returns:
- Returns the service representations in the form of
ServiceReferenceDTO
objects. - Throws:
Exception
- An exception representing a failure in the underlying remote call.
-
installBundle
Install a new bundle given by an externally reachable location string, typically describing a URL. -
setBundleStartLevel
Set the start level for a bundle given by its bundle Id.- Parameters:
id
- Addresses the bundle by its identifier.startLevel
- The target start level.- Throws:
Exception
- An exception representing a failure in the underlying remote call.
-
setFrameworkStartLevel
Sets the current framework start level.- Parameters:
startLevel
- set the framework start level to this target.- Throws:
Exception
- An exception representing a failure in the underlying remote call.
-
startBundle
Start a bundle given by its bundle Id.- Parameters:
id
- Addresses the bundle by its identifier.- Throws:
Exception
- An exception representing a failure in the underlying remote call.
-
startBundle
Start a bundle given by its bundle Id.- Parameters:
id
- Addresses the bundle by its identifier.options
- Passes additional options as defined inBundle.start(int)
- Throws:
Exception
- An exception representing a failure in the underlying remote call.
-
stopBundle
Stop a bundle given by its bundle Id.- Parameters:
id
- Addresses the bundle by its identifier.- Throws:
Exception
- An exception representing a failure in the underlying remote call.
-
stopBundle
Stop a bundle given by its bundle Id.- Parameters:
id
- Addresses the bundle by its identifier.options
- Passes additional options as defined inBundle.stop(int)
- Throws:
Exception
- An exception representing a failure in the underlying remote call.
-
uninstallBundle
Uninstall a bundle given by its bundle Id. -
updateBundle
Updates a bundle given by its bundle Id using the bundle-internal update location. -
updateBundle
Updates a bundle given by its URI path using the content at the specified URL.
-