public class BridgePropertyPlaceholderConfigurer
extends org.springframework.beans.factory.config.PropertyPlaceholderConfigurer
implements org.apache.camel.component.properties.PropertiesResolver, org.apache.camel.component.properties.AugmentedPropertyNameAwarePropertiesParser
PropertyPlaceholderConfigurer
that bridges Camel's
property placeholder with the Spring property placeholder mechanism.SYSTEM_PROPERTIES_MODE_FALLBACK, SYSTEM_PROPERTIES_MODE_NEVER, SYSTEM_PROPERTIES_MODE_OVERRIDE
DEFAULT_PLACEHOLDER_PREFIX, DEFAULT_PLACEHOLDER_SUFFIX, DEFAULT_VALUE_SEPARATOR, ignoreUnresolvablePlaceholders, nullValue, placeholderPrefix, placeholderSuffix, valueSeparator
Constructor and Description |
---|
BridgePropertyPlaceholderConfigurer() |
Modifier and Type | Method and Description |
---|---|
String |
parseProperty(String key,
String value,
Properties properties) |
String |
parseUri(String text,
Properties properties,
String prefixToken,
String suffixToken) |
String |
parseUri(String text,
Properties properties,
String prefixToken,
String suffixToken,
String propertyPrefix,
String propertySuffix,
boolean fallbackToUnaugmentedProperty) |
protected void |
processProperties(org.springframework.beans.factory.config.ConfigurableListableBeanFactory beanFactoryToProcess,
Properties props) |
Properties |
resolveProperties(org.apache.camel.CamelContext context,
boolean ignoreMissingLocation,
String... uri) |
void |
setBeanName(String beanName) |
void |
setIgnoreUnresolvablePlaceholders(boolean ignoreUnresolvablePlaceholders) |
void |
setParser(org.apache.camel.component.properties.PropertiesParser parser) |
void |
setPlaceholderPrefix(String placeholderPrefix) |
void |
setPlaceholderSuffix(String placeholderSuffix) |
void |
setResolver(org.apache.camel.component.properties.PropertiesResolver resolver) |
void |
setSystemPropertiesMode(int systemPropertiesMode) |
void |
setSystemPropertiesModeName(String constantName) |
void |
setValueSeparator(String valueSeparator) |
protected String |
springResolvePlaceholders(String text,
Properties properties)
Resolves the placeholders using Spring's property placeholder functionality.
|
parseStringValue, resolvePlaceholder, resolvePlaceholder, resolveSystemProperty, setSearchSystemEnvironment
doProcessProperties, setBeanFactory, setNullValue
convertProperties, convertProperty, convertPropertyValue, getOrder, postProcessBeanFactory, setOrder
protected void processProperties(org.springframework.beans.factory.config.ConfigurableListableBeanFactory beanFactoryToProcess, Properties props) throws org.springframework.beans.BeansException
processProperties
in class org.springframework.beans.factory.config.PropertyPlaceholderConfigurer
org.springframework.beans.BeansException
public void setBeanName(String beanName)
setBeanName
in interface org.springframework.beans.factory.BeanNameAware
setBeanName
in class org.springframework.beans.factory.config.PlaceholderConfigurerSupport
public void setSystemPropertiesModeName(String constantName) throws IllegalArgumentException
setSystemPropertiesModeName
in class org.springframework.beans.factory.config.PropertyPlaceholderConfigurer
IllegalArgumentException
public void setSystemPropertiesMode(int systemPropertiesMode)
setSystemPropertiesMode
in class org.springframework.beans.factory.config.PropertyPlaceholderConfigurer
public void setPlaceholderPrefix(String placeholderPrefix)
setPlaceholderPrefix
in class org.springframework.beans.factory.config.PlaceholderConfigurerSupport
public void setPlaceholderSuffix(String placeholderSuffix)
setPlaceholderSuffix
in class org.springframework.beans.factory.config.PlaceholderConfigurerSupport
public void setValueSeparator(String valueSeparator)
setValueSeparator
in class org.springframework.beans.factory.config.PlaceholderConfigurerSupport
public void setIgnoreUnresolvablePlaceholders(boolean ignoreUnresolvablePlaceholders)
setIgnoreUnresolvablePlaceholders
in class org.springframework.beans.factory.config.PlaceholderConfigurerSupport
public Properties resolveProperties(org.apache.camel.CamelContext context, boolean ignoreMissingLocation, String... uri) throws Exception
resolveProperties
in interface org.apache.camel.component.properties.PropertiesResolver
Exception
public String parseUri(String text, Properties properties, String prefixToken, String suffixToken, String propertyPrefix, String propertySuffix, boolean fallbackToUnaugmentedProperty) throws IllegalArgumentException
parseUri
in interface org.apache.camel.component.properties.AugmentedPropertyNameAwarePropertiesParser
IllegalArgumentException
public String parseUri(String text, Properties properties, String prefixToken, String suffixToken) throws IllegalArgumentException
parseUri
in interface org.apache.camel.component.properties.PropertiesParser
IllegalArgumentException
public String parseProperty(String key, String value, Properties properties)
parseProperty
in interface org.apache.camel.component.properties.PropertiesParser
protected String springResolvePlaceholders(String text, Properties properties)
text
- the text which may contain spring placeholdersproperties
- the propertiespublic void setResolver(org.apache.camel.component.properties.PropertiesResolver resolver)
public void setParser(org.apache.camel.component.properties.PropertiesParser parser)
Apache Camel