|
17 | 17 | package org.springframework.beans.factory.config;
|
18 | 18 |
|
19 | 19 | import java.util.Properties;
|
| 20 | +import java.util.Set; |
20 | 21 |
|
21 | 22 | import org.springframework.beans.BeansException;
|
22 | 23 | import org.springframework.beans.factory.BeanDefinitionStoreException;
|
@@ -352,12 +353,25 @@ protected String resolveSystemProperty(String key) {
|
352 | 353 | }
|
353 | 354 | }
|
354 | 355 |
|
355 |
| - |
356 | 356 | /**
|
357 |
| - * BeanDefinitionVisitor that resolves placeholders in String values, |
358 |
| - * delegating to the <code>parseStringValue</code> method of the |
359 |
| - * containing class. |
| 357 | + * Parse the given String value for placeholder resolution. |
| 358 | + * @param strVal the String value to parse |
| 359 | + * @param props the Properties to resolve placeholders against |
| 360 | + * @param visitedPlaceholders the placeholders that have already been visited |
| 361 | + * during the current resolution attempt (ignored in this version of the code) |
| 362 | + * @deprecated as of Spring 3.0, in favor of using {@link #resolvePlaceholder} |
| 363 | + * with {@link org.springframework.util.PropertyPlaceholderHelper}. |
| 364 | + * Only retained for compatibility with Spring 2.5 extensions. |
360 | 365 | */
|
| 366 | + @Deprecated |
| 367 | + protected String parseStringValue(String strVal, Properties props, Set visitedPlaceholders) { |
| 368 | + PropertyPlaceholderHelper helper = new PropertyPlaceholderHelper( |
| 369 | + placeholderPrefix, placeholderSuffix, valueSeparator, ignoreUnresolvablePlaceholders); |
| 370 | + PlaceholderResolver resolver = new PropertyPlaceholderConfigurerResolver(props); |
| 371 | + return helper.replacePlaceholders(strVal, resolver); |
| 372 | + } |
| 373 | + |
| 374 | + |
361 | 375 | private class PlaceholderResolvingStringValueResolver implements StringValueResolver {
|
362 | 376 |
|
363 | 377 | private final PropertyPlaceholderHelper helper;
|
|
0 commit comments