ServiceReference<BindingAwareBroker> brokerRef = context.getServiceReference(BindingAwareBroker.class);
BindingAwareBroker broker = context.getService(brokerRef);
broker.registerConsumer(this, context);
+ startImpl(context);
//context.ungetService(brokerRef);
}
+ @Deprecated
+ abstract protected void startImpl(BundleContext context);
+
@Override
public final void stop(BundleContext context) throws Exception {
// TODO Auto-generated method stub
ServiceReference<BindingAwareBroker> brokerRef = context.getServiceReference(BindingAwareBroker.class);
BindingAwareBroker broker = context.getService(brokerRef);
broker.registerProvider(this, context);
+ startImpl(context);
}
-
+
+ @Deprecated
+ abstract protected void startImpl(BundleContext context);
+
@Override
public final void stop(BundleContext context) throws Exception {
return false;
}
+
+ @Override
+ @Deprecated
+ protected void startImpl(BundleContext context) {
+ context.registerService(ToastConsumer.class, this, new Hashtable<String,String>());
+ }
@Override
public void onSessionInitialized(ConsumerContext session) {
public Collection<? extends ProviderFunctionality> getFunctionality() {
return Collections.emptySet();
}
+
+ @Override
+ @Deprecated
+ protected void startImpl(BundleContext context) {
+ // TODO Auto-generated method stub
+
+ }
}