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