public final class ConfigurationProvider extends Object
Configuration
for the very application.Modifier and Type | Method and Description |
---|---|
static Configuration |
getConfiguration()
Access the current configuration.
|
static ConfigurationContext |
getConfigurationContext()
Deprecated.
Use
Configuration.getContext() instead of. |
static ConfigurationContextBuilder |
getConfigurationContextBuilder()
Create a new
ConfigurationContextBuilder instance. |
static void |
setConfigurationContext(ConfigurationContext context)
This method allows to replace the current
ConfigurationContext with a new
instance. |
public static Configuration getConfiguration()
@Deprecated public static ConfigurationContext getConfigurationContext()
Configuration.getContext()
instead of.public static void setConfigurationContext(ConfigurationContext context)
ConfigurationContext
with a new
instance. This can be used to update the context with a new one, e.g. because some of the configuration
data has changed and should be updated. It is the responsibility of the ConfigurationProvider to trigger
corresponding update events for the current Configuration
, so observing
listeners can do whatever is appropriate to react to any given configuration changes.context
- the new ConfigurationContext to be applied.UnsupportedOperationException
- if the current provider is read-only and does not support
applying a new ConfigurationContext.public static ConfigurationContextBuilder getConfigurationContextBuilder()
ConfigurationContextBuilder
instance. This method creates
a new builder instance that is not related to any concrete ConfigurationContext
.
You can use setConfigurationContext(org.apache.tamaya.spi.ConfigurationContext)
to change the
current configuration context.ConfigurationContextBuilder
, never null.setConfigurationContext(org.apache.tamaya.spi.ConfigurationContext)
,
ConfigurationContext
Copyright © 2014–2016 Apache Software Foundation. All rights reserved.