Class ConfigurationMetadataProviderMultiplexerImpl
java.lang.Object
org.apache.sling.caconfig.impl.metadata.ConfigurationMetadataProviderMultiplexerImpl
- All Implemented Interfaces:
ConfigurationMetadataProviderMultiplexer
,ConfigurationMetadataProvider
public class ConfigurationMetadataProviderMultiplexerImpl
extends Object
implements ConfigurationMetadataProviderMultiplexer
Detects all
ConfigurationMetadataProvider
implementations in the container
and consolidates their result based on service ranking.-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected void
bindConfigurationMetadataProvider
(ConfigurationMetadataProvider configurationMetadataProvider, Map<String, Object> props) getConfigurationMetadata
(String configName) Get configuration metadata from first provider (ranking priority) that has an answer.Merge configuration names from all providers.protected void
unbindConfigurationMetadataProvider
(ConfigurationMetadataProvider configurationMetadataProvider, Map<String, Object> props)
-
Constructor Details
-
ConfigurationMetadataProviderMultiplexerImpl
public ConfigurationMetadataProviderMultiplexerImpl()
-
-
Method Details
-
bindConfigurationMetadataProvider
protected void bindConfigurationMetadataProvider(ConfigurationMetadataProvider configurationMetadataProvider, Map<String, Object> props) -
unbindConfigurationMetadataProvider
protected void unbindConfigurationMetadataProvider(ConfigurationMetadataProvider configurationMetadataProvider, Map<String, Object> props) -
getConfigurationNames
Merge configuration names from all providers.- Specified by:
getConfigurationNames
in interfaceConfigurationMetadataProvider
- Returns:
- Configuration names
-
getConfigurationMetadata
Get configuration metadata from first provider (ranking priority) that has an answer.- Specified by:
getConfigurationMetadata
in interfaceConfigurationMetadataProvider
- Parameters:
configName
- Configuration name- Returns:
- Configuration metadata or null if none exists for the given name.
-