|
89 | 89 | <xsd:element name="property-placeholder">
|
90 | 90 | <xsd:annotation>
|
91 | 91 | <xsd:documentation><![CDATA[
|
92 |
| - Activates replacement of ${...} placeholders, resolved against the specified properties file or |
93 |
| - Properties object (if any). Defines a PropertySourcesPlaceholderConfigurer within the context. |
94 |
| - For backward compatibility with versions earlier than Spring 3.1, a PropertyPlaceholderConfigurer will be |
95 |
| - registered if the 'system-properties-mode' attribute has been explicitly assigned a value. |
| 92 | + Activates replacement of ${...} placeholders by registering a |
| 93 | + PropertySourcesPlaceholderConfigurer within the application context. Properties will |
| 94 | + be resolved against the specified properties file or Properties object -- so called |
| 95 | + "local properties", if any, and against the Spring Environment's current set of |
| 96 | + PropertySources. |
| 97 | +
|
| 98 | + Note that as of Spring 3.1 the system-properties-mode attribute has been removed in |
| 99 | + favor of the more flexible PropertySources mechanism. However, Spring 3.1-based |
| 100 | + applications may continue to use the 3.0 (and older) versions of the spring-context |
| 101 | + schema in order to preserve system-properties-mode behavior. In this case, the |
| 102 | + traditional PropertyPlaceholderConfigurer component will be registered instead of the |
| 103 | + new PropertySourcesPlaceholderConfigurer. |
| 104 | +
|
| 105 | + See ConfigurableEnvironment Javadoc for more information on using. |
96 | 106 | ]]></xsd:documentation>
|
97 | 107 | <xsd:appinfo>
|
98 | 108 | <tool:annotation>
|
|
103 | 113 | </xsd:annotation>
|
104 | 114 | <xsd:complexType>
|
105 | 115 | <xsd:complexContent>
|
106 |
| - <xsd:extension base="propertyPlaceholder" /> |
| 116 | + <xsd:extension base="propertyPlaceholder"> |
| 117 | + <xsd:attribute name="system-properties-mode" default="ENVIRONMENT"> |
| 118 | + <xsd:annotation> |
| 119 | + <xsd:documentation><![CDATA[ |
| 120 | + Controls how to resolve placeholders against system properties. As of Spring 3.1, this |
| 121 | + attribute value defaults to "ENVIRONMENT", indicating that resolution of placeholders |
| 122 | + against system properties is handled via PropertySourcesPlaceholderConfigurer and its |
| 123 | + delegation to the current Spring Environment object. |
| 124 | +
|
| 125 | + For maximum backward compatibility, this attribute is preserved going forward with the |
| 126 | + 3.1 version of the context schema, and any values other than the default "ENVIRONMENT" |
| 127 | + will cause a traditional PropertyPlaceholderConfigurer to be registered instead of the |
| 128 | + newer PropertySourcesPlaceholderConfigurer variant. In this case, the Spring Environment |
| 129 | + and its property sources are not interrogated when resolving placeholders. Users are |
| 130 | + encouraged to consider this attribute deprecated, and to take advantage of |
| 131 | + Environment/PropertySource mechanisms. See ConfigurableEnvironment Javadoc for examples. |
| 132 | +
|
| 133 | + "ENVIRONMENT" indicates placeholders should be resolved against the current Environment and against any local properties; |
| 134 | + "NEVER" indicates placeholders should be resolved only against local properties and never against system properties; |
| 135 | + "FALLBACK" indicates placeholders should be resolved against any local properties and then against system properties; |
| 136 | + "OVERRIDE" indicates placeholders should be resolved first against system properties and then against any local properties; |
| 137 | + ]]></xsd:documentation> |
| 138 | + </xsd:annotation> |
| 139 | + <xsd:simpleType> |
| 140 | + <xsd:restriction base="xsd:string"> |
| 141 | + <xsd:enumeration value="ENVIRONMENT"/> |
| 142 | + <xsd:enumeration value="NEVER"/> |
| 143 | + <xsd:enumeration value="FALLBACK"/> |
| 144 | + <xsd:enumeration value="OVERRIDE"/> |
| 145 | + </xsd:restriction> |
| 146 | + </xsd:simpleType> |
| 147 | + </xsd:attribute> |
| 148 | + </xsd:extension> |
107 | 149 | </xsd:complexContent>
|
108 | 150 | </xsd:complexType>
|
109 | 151 | </xsd:element>
|
|
360 | 402 | Signals the current application context to apply dependency injection
|
361 | 403 | to non-managed classes that are instantiated outside of the Spring bean
|
362 | 404 | factory (typically classes annotated with the @Configurable annotation).
|
363 |
| -
|
364 |
| - See Javadoc for org.springframework.context.annotation.EnableSpringConfigured in the |
365 |
| - spring-aspects module for information on code-based alternatives to bootstrapping |
366 |
| - this functionality. |
367 | 405 | ]]></xsd:documentation>
|
368 | 406 | </xsd:annotation>
|
369 | 407 | <xsd:simpleType>
|
|
0 commit comments