@ -17,6 +17,7 @@
@@ -17,6 +17,7 @@
package org.springframework.beans.factory.config ;
import java.util.Properties ;
import java.util.Set ;
import org.springframework.beans.BeansException ;
import org.springframework.beans.factory.BeanDefinitionStoreException ;
@ -352,12 +353,25 @@ public class PropertyPlaceholderConfigurer extends PropertyResourceConfigurer
@@ -352,12 +353,25 @@ public class PropertyPlaceholderConfigurer extends PropertyResourceConfigurer
}
}
/ * *
* BeanDefinitionVisitor that resolves placeholders in String values ,
* delegating to the < code > parseStringValue < / code > method of the
* containing class .
* Parse the given String value for placeholder resolution .
* @param strVal the String value to parse
* @param props the Properties to resolve placeholders against
* @param visitedPlaceholders the placeholders that have already been visited
* during the current resolution attempt ( ignored in this version of the code )
* @deprecated as of Spring 3 . 0 , in favor of using { @link # resolvePlaceholder }
* with { @link org . springframework . util . PropertyPlaceholderHelper } .
* Only retained for compatibility with Spring 2 . 5 extensions .
* /
@Deprecated
protected String parseStringValue ( String strVal , Properties props , Set visitedPlaceholders ) {
PropertyPlaceholderHelper helper = new PropertyPlaceholderHelper (
placeholderPrefix , placeholderSuffix , valueSeparator , ignoreUnresolvablePlaceholders ) ;
PlaceholderResolver resolver = new PropertyPlaceholderConfigurerResolver ( props ) ;
return helper . replacePlaceholders ( strVal , resolver ) ;
}
private class PlaceholderResolvingStringValueResolver implements StringValueResolver {
private final PropertyPlaceholderHelper helper ;