public class Activator extends AbstractExtender
| Modifier and Type | Class and Description |
|---|---|
protected class |
Activator.ScrExtension |
| Modifier and Type | Field and Description |
|---|---|
private ScrLogger |
logger |
private org.osgi.framework.Bundle |
m_bundle |
private ComponentActorThread |
m_componentActor |
private java.util.Map<java.lang.Long,BundleComponentActivator> |
m_componentBundles |
private ComponentCommands |
m_componentCommands |
private ComponentRegistry |
m_componentRegistry |
private ScrConfigurationImpl |
m_configuration |
private org.osgi.framework.BundleContext |
m_context |
private org.osgi.framework.BundleContext |
m_globalContext |
private org.osgi.framework.ServiceRegistration<org.osgi.service.component.runtime.ServiceComponentRuntime> |
m_runtime_reg |
| Constructor and Description |
|---|
Activator() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
debug(org.osgi.framework.Bundle bundle,
java.lang.String msg) |
private void |
disposeComponents(org.osgi.framework.Bundle bundle)
Unloads components of the given bundle.
|
protected Activator.ScrExtension |
doCreateExtension(org.osgi.framework.Bundle bundle)
Create the extension for the given bundle, or null if the bundle is not to be extended.
|
protected void |
doStart() |
void |
doStop()
Unregisters this instance as a bundle listener and unloads all components
which have been registered during the active life time of the SCR
implementation bundle.
|
private void |
loadComponents(org.osgi.framework.Bundle bundle)
Loads the components of the given bundle.
|
void |
restart(boolean globalExtender) |
void |
start(org.osgi.framework.BundleContext context)
Registers this instance as a (synchronous) bundle listener and loads the
components of already registered bundles.
|
void |
stop(org.osgi.framework.BundleContext context) |
protected void |
warn(org.osgi.framework.Bundle bundle,
java.lang.String msg,
java.lang.Throwable t) |
addingBundle, bundleChanged, chooseBundlesToDestroy, createExecutor, getBundleContext, isStopping, modifiedBundle, removedBundle, startTracking, stopTrackingprivate final ScrConfigurationImpl m_configuration
private org.osgi.framework.BundleContext m_context
private org.osgi.framework.BundleContext m_globalContext
private org.osgi.framework.Bundle m_bundle
private volatile ScrLogger logger
private java.util.Map<java.lang.Long,BundleComponentActivator> m_componentBundles
private ComponentRegistry m_componentRegistry
private ComponentActorThread m_componentActor
private org.osgi.framework.ServiceRegistration<org.osgi.service.component.runtime.ServiceComponentRuntime> m_runtime_reg
private ComponentCommands m_componentCommands
public void start(org.osgi.framework.BundleContext context)
throws java.lang.Exception
start in interface org.osgi.framework.BundleActivatorstart in class AbstractExtendercontext - The BundleContext of the SCR implementation
bundle.java.lang.Exceptionpublic void restart(boolean globalExtender)
protected void doStart()
throws java.lang.Exception
doStart in class AbstractExtenderjava.lang.Exceptionpublic void stop(org.osgi.framework.BundleContext context)
throws java.lang.Exception
stop in interface org.osgi.framework.BundleActivatorstop in class AbstractExtenderjava.lang.Exceptionpublic void doStop()
throws java.lang.Exception
doStop in class AbstractExtenderjava.lang.Exceptionprotected Activator.ScrExtension doCreateExtension(org.osgi.framework.Bundle bundle) throws java.lang.Exception
AbstractExtenderdoCreateExtension in class AbstractExtenderbundle - the bundle to extendjava.lang.Exception - If something goes wrongprivate void loadComponents(org.osgi.framework.Bundle bundle)
This method calls the Bundle.getBundleContext() method to find
the BundleContext of the bundle. If the context cannot be
found, this method does not load components for the bundle.
private void disposeComponents(org.osgi.framework.Bundle bundle)
protected void debug(org.osgi.framework.Bundle bundle,
java.lang.String msg)
debug in class AbstractExtenderprotected void warn(org.osgi.framework.Bundle bundle,
java.lang.String msg,
java.lang.Throwable t)
warn in class AbstractExtender