public abstract class BaseManagedServiceFactory<T> extends Object implements org.osgi.service.cm.ManagedServiceFactory
Modifier and Type | Field and Description |
---|---|
static long |
DEFAULT_TIMEOUT_BEFORE_INTERRUPT |
protected org.slf4j.Logger |
LOGGER |
Constructor and Description |
---|
BaseManagedServiceFactory(org.osgi.framework.BundleContext context,
String name) |
BaseManagedServiceFactory(org.osgi.framework.BundleContext context,
String name,
long timeoutBeforeInterrupt) |
Modifier and Type | Method and Description |
---|---|
protected void |
checkConfiguration(String pid,
Dictionary properties) |
void |
deleted(String pid) |
void |
destroy() |
protected abstract T |
doCreate(Dictionary<String,?> properties) |
protected abstract void |
doDestroy(T t) |
protected T |
doUpdate(T t,
Dictionary<String,?> properties) |
protected Future<?> |
execute(Runnable runnable) |
protected abstract String[] |
getExposedClasses(T t) |
String |
getName() |
protected Map<String,io.fabric8.osgimetadata.BaseManagedServiceFactory.Pair<T,org.osgi.framework.ServiceRegistration>> |
getServices() |
boolean |
isDestroyed() |
void |
updated(String pid,
Dictionary<String,?> properties) |
public static final long DEFAULT_TIMEOUT_BEFORE_INTERRUPT
protected final org.slf4j.Logger LOGGER
public BaseManagedServiceFactory(org.osgi.framework.BundleContext context, String name)
public BaseManagedServiceFactory(org.osgi.framework.BundleContext context, String name, long timeoutBeforeInterrupt)
public String getName()
getName
in interface org.osgi.service.cm.ManagedServiceFactory
protected Map<String,io.fabric8.osgimetadata.BaseManagedServiceFactory.Pair<T,org.osgi.framework.ServiceRegistration>> getServices()
public boolean isDestroyed()
public void updated(String pid, Dictionary<String,?> properties) throws org.osgi.service.cm.ConfigurationException
updated
in interface org.osgi.service.cm.ManagedServiceFactory
org.osgi.service.cm.ConfigurationException
public void deleted(String pid)
deleted
in interface org.osgi.service.cm.ManagedServiceFactory
protected void checkConfiguration(String pid, Dictionary properties) throws org.osgi.service.cm.ConfigurationException
org.osgi.service.cm.ConfigurationException
protected abstract T doCreate(Dictionary<String,?> properties) throws Exception
Exception
protected T doUpdate(T t, Dictionary<String,?> properties) throws Exception
Exception
public void destroy()
Copyright © 2011–2014 Red Hat. All rights reserved.