|
Service Activator Toolkit
Version 1.0.0 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.soda.sat.core.framework.BundleActivationManagerOwnerAdapter
The BundleActivationManagerOwnerAdapter is a no-op
implementation of the interface IBundleActivationManagerOwner.
This class is useful for creating an owner of an IBundleActivationManager
that only requires to handle a subset of the possible call-backs,
which is common.
| Field Summary |
| Fields inherited from interface org.eclipse.soda.sat.core.framework.interfaces.IBundleActivationManagerOwner |
NO_SERVICES |
| Constructor Summary | |
BundleActivationManagerOwnerAdapter()
|
|
| Method Summary | |
void |
activate()
Hook Method: You have been activated. |
void |
deactivate()
Hook Method: You have been deactivated. |
int |
getAsyncStartPriority()
Configuration Parameter Method: Get the async start thread priority. |
String[] |
getImportedServiceNames()
Query Method: Answers the names of all the services that are imported by the bundle. |
String[] |
getOptionalImportedServiceNames()
Query Method: Answers the names of all the services that are optionally imported by the bundle. |
InputStream |
getPropertiesInputStream()
Hook Method: Get an input stream to the bundle's properties. |
void |
handleAcquiredOptionalImportedService(String serviceName,
Object service)
Hook Handler Method: When an optional imported service is acquired, this method is called. |
boolean |
handleException(Exception exception)
Hook Handler Method: Handles a thrown exception. |
void |
handleFailedToFindProperties(String filename)
Hook Handler Method: Handle the fact that the specified properties file could not be found. |
void |
handleReleasedOptionalImportedService(String serviceName,
Object service)
Hook Handler Method: When an optional imported service is released this method is called. |
boolean |
isStartAsync()
Configuration Parameter Method: Specifies whether the bundle should start asynchronously. |
boolean |
isTransient()
Configuration Parameter Method: Specify whether the bundle should be treated as transient. |
boolean |
isUninstallable()
Configuration Parameter Method: Specify whether the bundle should be treated as uninstalled. |
void |
start()
Hook Method: This method is called when the
IBundleActivatorManager executes its start(BundleContext)
method. |
void |
stop()
Hook Method: This method is called when the
IBundleActivatorManager executes its stop(BundleContext)
method. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public BundleActivationManagerOwnerAdapter()
| Method Detail |
public void activate()
IBundleActivationManagerOwner
activate in interface IBundleActivationManagerOwnerIBundleActivationManagerOwner.activate()public void deactivate()
IBundleActivationManagerOwner
deactivate in interface IBundleActivationManagerOwnerIBundleActivationManagerOwner.deactivate()public int getAsyncStartPriority()
IBundleActivationManagerOwnerisStartAsync() to return true and
wish to specify a thread priority other than Thread.NORM_PRIORITY
.
getAsyncStartPriority in interface IBundleActivationManagerOwnerIBundleActivationManagerOwner.getAsyncStartPriority()public String[] getImportedServiceNames()
IBundleActivationManagerOwner
getImportedServiceNames in interface IBundleActivationManagerOwnerIBundleActivationManagerOwner.getImportedServiceNames()public String[] getOptionalImportedServiceNames()
IBundleActivationManagerOwner
getOptionalImportedServiceNames in interface IBundleActivationManagerOwnerIBundleActivationManagerOwner.getOptionalImportedServiceNames()
public InputStream getPropertiesInputStream()
throws IOException
IBundleActivationManagerOwner
getPropertiesInputStream in interface IBundleActivationManagerOwnernull if the
bundle does not have any properties.
IOExceptionIBundleActivationManagerOwner.getPropertiesInputStream()
public void handleAcquiredOptionalImportedService(String serviceName,
Object service)
IBundleActivationManagerOwner
handleAcquiredOptionalImportedService in interface IBundleActivationManagerOwnerserviceName - The fully-qualified name of the optional imported
service.service - The acquired optional imported service.IBundleActivationManagerOwner.handleAcquiredOptionalImportedService(java.lang.String, java.lang.Object)public boolean handleException(Exception exception)
IBundleActivationManagerOwner
handleException in interface IBundleActivationManagerOwnerexception - The unhandled exception.
IBundleActivationManagerOwner.handleException(java.lang.Exception)public void handleFailedToFindProperties(String filename)
IBundleActivationManagerOwner
handleFailedToFindProperties in interface IBundleActivationManagerOwnerfilename - The name of the properties file.IBundleActivationManagerOwner.handleFailedToFindProperties(java.lang.String)
public void handleReleasedOptionalImportedService(String serviceName,
Object service)
IBundleActivationManagerOwner
handleReleasedOptionalImportedService in interface IBundleActivationManagerOwnerserviceName - The fully-qualified name of the optional imported
service.service - The released optional imported service.IBundleActivationManagerOwner.handleReleasedOptionalImportedService(java.lang.String, java.lang.Object)public boolean isStartAsync()
IBundleActivationManagerOwner
isStartAsync in interface IBundleActivationManagerOwnerIBundleActivationManagerOwner.isStartAsync()public boolean isTransient()
IBundleActivationManagerOwnerBundle.ACTIVE state.
This method should be implemented by bundles that are to be considered
transient.
Note:
isUninstallable().
isTransient in interface IBundleActivationManagerOwnerIBundleActivationManagerOwner.isTransient()public boolean isUninstallable()
IBundleActivationManagerOwnertrue by bundles that are
uninstallable prerequisites.
Note:
isTransient().
isUninstallable in interface IBundleActivationManagerOwnerIBundleActivationManagerOwner.isUninstallable()
public void start()
throws Exception
IBundleActivationManagerOwner
IBundleActivatorManager executes its start(BundleContext)
method. This method is implemented by bundles that wish to
perform behavior exactly once when the bundle starts.
start in interface IBundleActivationManagerOwnerExceptionIBundleActivationManagerOwner.start()
public void stop()
throws Exception
IBundleActivationManagerOwner
IBundleActivatorManager executes its stop(BundleContext)
method. This method is implemented by bundles that wish to
perform behavior exactly once when the bundle stops.
stop in interface IBundleActivationManagerOwnerExceptionIBundleActivationManagerOwner.stop()
|
Service Activator Toolkit
Version 1.0.0 |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
Copyright © 2001, 2007 IBM Corporation and others. All Rights Reserved.