import org.apache.felix.dm.ServiceDependency;
import org.osgi.framework.BundleActivator;
import org.osgi.framework.BundleContext;
-import org.osgi.framework.ServiceRegistration;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
BundleActivator, IContainerAware {
Logger logger = LoggerFactory
.getLogger(ComponentActivatorAbstractBase.class);
- private ServiceRegistration containerAwareRegistration;
private DependencyManager dm;
private ConcurrentMap<ImmutablePair<String, Object>, Component> dbInstances = (ConcurrentMap<ImmutablePair<String, Object>, Component>) new ConcurrentHashMap<ImmutablePair<String, Object>, Component>();
private ConcurrentMap<Object, Component> dbGlobalInstances = (ConcurrentMap<Object, Component>) new ConcurrentHashMap<Object, Component>();
@Override
public void stopped(Component component) {
+ // do nothing
+ }
+
+ @Override
+ public void stopping(Component component) {
if (component == null) {
return;
}
{ Component.class }, {} }, new Object[][] { { component },
{} });
}
-
- @Override
- public void stopping(Component component) {
- // do nothing
- }
}
/**
}
// Register with OSGi the provider for the service IContainerAware
- this.containerAwareRegistration = context.registerService(
+ context.registerService(
IContainerAware.class.getName(), this, null);
// Now call the derived class init function