
public class ConfigurationInstancesStorageImpl extends Object implements ConfigurationInstancesStorage
| Constructor and Description |
|---|
ConfigurationInstancesStorageImpl()
load all instances.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addConfigurationInstance(ConfigurationInstance instance)
Adds the configuration instance and saves it to the physical storage.
|
void |
addListener(StorageChangedListener listener) |
boolean |
contains(ConfigurationInstance configInstance) |
List<ConfigurationInstance> |
getAllInstancesForBundle(String bundlename) |
ConfigurationInstance |
getConfigurationForBundle(org.osgi.framework.Bundle bundle)
returns the first primary configuration instance or if there is no
primary instance then this method returns the first configuration
instance for the given bundle.
|
void |
loadInstances()
load the instances from file system.
|
boolean |
removeConfigurationInstance(ConfigurationInstance instance)
Removes the given instance also from the physical storage
|
void |
removeListener(StorageChangedListener listener) |
void |
replaceConfigurationInstance(ConfigurationInstance instance)
Replace the instance with the same id.
|
public ConfigurationInstancesStorageImpl()
public void loadInstances()
loadInstances in interface ConfigurationInstancesStoragepublic void addConfigurationInstance(ConfigurationInstance instance)
ConfigurationInstancesStorageaddConfigurationInstance in interface ConfigurationInstancesStoragepublic void replaceConfigurationInstance(ConfigurationInstance instance)
ConfigurationInstancesStoragereplaceConfigurationInstance in interface ConfigurationInstancesStoragepublic boolean removeConfigurationInstance(ConfigurationInstance instance)
ConfigurationInstancesStorageremoveConfigurationInstance in interface ConfigurationInstancesStoragepublic List<ConfigurationInstance> getAllInstancesForBundle(String bundlename)
getAllInstancesForBundle in interface ConfigurationInstancesStoragepublic boolean contains(ConfigurationInstance configInstance)
contains in interface ConfigurationInstancesStoragepublic ConfigurationInstance getConfigurationForBundle(org.osgi.framework.Bundle bundle) throws NoConfigurationFoundException
getConfigurationForBundle in interface ConfigurationInstancesStorageNoConfigurationFoundExceptionpublic void addListener(StorageChangedListener listener)
addListener in interface ConfigurationInstancesStoragepublic void removeListener(StorageChangedListener listener)
removeListener in interface ConfigurationInstancesStorageCopyright © 2018 universAAL Consortium. All rights reserved.