Class ConfigExtensionManager<E,C>
- java.lang.Object
-
- org.opennms.features.apilayer.config.ConfigExtensionManager<E,C>
-
- Type Parameters:
E
- extension interface typeC
- configuration bean type
- All Implemented Interfaces:
ConfigurationProvider
- Direct Known Subclasses:
EventConfExtensionManager
,GraphPropertiesExtensionManager
,ResourceTypesExtensionManager
,SnmpCollectionExtensionManager
,SyslogMatchExtensionManager
,ThreshdConfigurationExtensionManager
,ThresholdingConfigExtensionManager
public abstract class ConfigExtensionManager<E,C> extends java.lang.Object implements ConfigurationProvider
AConfigurationProvider
which is driven by API extensions.
-
-
Constructor Summary
Constructors Constructor Description ConfigExtensionManager(java.lang.Class<C> clazz, C initialObject)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description void
deregisteredFromConfigReloadContainer()
Notifies this configuration provider that it was unregistered from theConfigReloadContainer
.protected abstract C
getConfigForExtensions(java.util.Set<E> extensions)
long
getLastUpdate()
C
getObject()
Retrieve the actual configuration bean.java.lang.Class<?>
getType()
Retrieve a class reference to the type of object returned byConfigurationProvider.getObject()
.void
onBind(E extension, java.util.Map properties)
void
onUnbind(E extension, java.util.Map properties)
void
registeredToConfigReloadContainer()
Notifies this configuration provider that it was registered with theConfigReloadContainer
.protected abstract void
triggerReload()
-
-
-
Method Detail
-
onBind
public void onBind(E extension, java.util.Map properties)
-
onUnbind
public void onUnbind(E extension, java.util.Map properties)
-
registeredToConfigReloadContainer
public void registeredToConfigReloadContainer()
Description copied from interface:ConfigurationProvider
Notifies this configuration provider that it was registered with theConfigReloadContainer
.- Specified by:
registeredToConfigReloadContainer
in interfaceConfigurationProvider
-
deregisteredFromConfigReloadContainer
public void deregisteredFromConfigReloadContainer()
Description copied from interface:ConfigurationProvider
Notifies this configuration provider that it was unregistered from theConfigReloadContainer
.- Specified by:
deregisteredFromConfigReloadContainer
in interfaceConfigurationProvider
-
triggerReload
protected abstract void triggerReload()
-
getType
public java.lang.Class<?> getType()
Description copied from interface:ConfigurationProvider
Retrieve a class reference to the type of object returned byConfigurationProvider.getObject()
. This is used instead of generics to be OSGi friendly.- Specified by:
getType
in interfaceConfigurationProvider
- Returns:
- the type of object returned by
ConfigurationProvider.getObject()
-
getObject
public C getObject()
Description copied from interface:ConfigurationProvider
Retrieve the actual configuration bean.- Specified by:
getObject
in interfaceConfigurationProvider
- Returns:
- the configuration bean, must be non-null
-
getLastUpdate
public long getLastUpdate()
- Specified by:
getLastUpdate
in interfaceConfigurationProvider
- Returns:
- the last time (in ms) at which the configuration bean was updated
-
-