Class PrefixedConfig
java.lang.Object
io.smallrye.reactive.messaging.providers.impl.PrefixedConfig
- All Implemented Interfaces:
org.eclipse.microprofile.config.Config
Represents a configuration class that allows overriding specific properties for a connector.
If a nested-channel is defined, property lookups will be in the following order
- If nested-channel is given try [prefix].[channel].[nested-channel].[property-key]
- If an override function is given for a property-key, calls it converts the return value
- Calls the
ConnectorConfigbase function
- See Also:
-
Field Summary
Fields inherited from interface org.eclipse.microprofile.config.Config
PROFILE, PROPERTY_EXPRESSIONS_ENABLED -
Constructor Summary
ConstructorsConstructorDescriptionPrefixedConfig(org.eclipse.microprofile.config.Config overall, String prefix) -
Method Summary
Modifier and TypeMethodDescriptionIterable<org.eclipse.microprofile.config.spi.ConfigSource> org.eclipse.microprofile.config.ConfigValuegetConfigValue(String propertyName) <T> Optional<org.eclipse.microprofile.config.spi.Converter<T>> getConverter(Class<T> forType) <T> Optional<T> getOptionalValue(String propertyName, Class<T> propertyType) Gets the lists of config keys for the given connector.<T> Tprotected booleannameExists(String name) protected StringnestedChannelKey(String keyName) static PrefixedConfigprotected String<T> TMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.eclipse.microprofile.config.Config
getOptionalValues, getValues
-
Constructor Details
-
PrefixedConfig
-
-
Method Details
-
prefixed
public static PrefixedConfig prefixed(String prefix, org.eclipse.microprofile.config.Config overall) -
nestedChannelKey
-
getValue
- Specified by:
getValuein interfaceorg.eclipse.microprofile.config.Config
-
getOptionalValue
- Specified by:
getOptionalValuein interfaceorg.eclipse.microprofile.config.Config
-
getConfigValue
- Specified by:
getConfigValuein interfaceorg.eclipse.microprofile.config.Config
-
getPropertyNames
Gets the lists of config keys for the given connector. Note that the list contains property names from the config and env variables. It includes keys from the connector config and channel config.- Specified by:
getPropertyNamesin interfaceorg.eclipse.microprofile.config.Config- Returns:
- the list of keys
-
toAlpha
-
nameExists
-
getConfigSources
- Specified by:
getConfigSourcesin interfaceorg.eclipse.microprofile.config.Config
-
getConverter
public <T> Optional<org.eclipse.microprofile.config.spi.Converter<T>> getConverter(Class<T> forType) - Specified by:
getConverterin interfaceorg.eclipse.microprofile.config.Config
-
unwrap
- Specified by:
unwrapin interfaceorg.eclipse.microprofile.config.Config
-