org.apache.aries.application.management.spi.framework
Interface BundleFramework


public interface BundleFramework


Field Summary
static String SHARED_BUNDLE_FRAMEWORK
           
 
Method Summary
 void close()
          Closes the framework and any associated resource
 List<Bundle> getBundles()
          Returns a list of bundles currently installed in this framework
 Bundle getFrameworkBundle()
          Returns the OSGi bundle representing the framework
 BundleContext getIsolatedBundleContext()
          Returns the bundle context for the framework.
 void init()
          Initialises the framework (but does not start the framework bundle)
 Bundle install(BundleRepository.BundleSuggestion suggestion, AriesApplication app)
          Installs a bundle to this framework.
 void start()
          Starts the framework and the framework bundle
 void start(Bundle b)
          Start a previously installed bundle in this framework.
 void stop(Bundle b)
          Stop a previously installed bundle in this framework.
 void uninstall(Bundle b)
          Removes a bundle from this framework
 

Field Detail

SHARED_BUNDLE_FRAMEWORK

static final String SHARED_BUNDLE_FRAMEWORK
See Also:
Constant Field Values
Method Detail

init

void init()
          throws BundleException
Initialises the framework (but does not start the framework bundle)

Throws:
BundleException

start

void start()
           throws BundleException
Starts the framework and the framework bundle

Throws:
BundleException

close

void close()
           throws BundleException
Closes the framework and any associated resource

Throws:
BundleException

install

Bundle install(BundleRepository.BundleSuggestion suggestion,
               AriesApplication app)
               throws BundleException
Installs a bundle to this framework.

Parameters:
suggestion - The information required to install the bundle
app - The application with which this install is associated
Returns:
the bundle that was installed
Throws:
BundleException

uninstall

void uninstall(Bundle b)
               throws BundleException
Removes a bundle from this framework

Parameters:
b - The bundle to remove
Throws:
BundleException

start

void start(Bundle b)
           throws BundleException
Start a previously installed bundle in this framework.

Parameters:
b - the bundle to start
Throws:
BundleException

stop

void stop(Bundle b)
          throws BundleException
Stop a previously installed bundle in this framework.

Parameters:
b - the bundle to stop
Throws:
BundleException

getIsolatedBundleContext

BundleContext getIsolatedBundleContext()
Returns the bundle context for the framework.

Returns:
a bundle context representing the framework

getFrameworkBundle

Bundle getFrameworkBundle()
Returns the OSGi bundle representing the framework

Returns:
a bundle representing the framework

getBundles

List<Bundle> getBundles()
Returns a list of bundles currently installed in this framework

Returns:
the bundles in the framework.


Copyright © 2009-2011 The Apache Software Foundation. All Rights Reserved.