Merge branch '5.3.x'
This commit is contained in:
commit
030ba52805
15
build.gradle
15
build.gradle
|
|
@ -128,10 +128,12 @@ configure(allprojects) { project ->
|
||||||
entry 'tomcat-embed-core'
|
entry 'tomcat-embed-core'
|
||||||
entry 'tomcat-embed-websocket'
|
entry 'tomcat-embed-websocket'
|
||||||
}
|
}
|
||||||
dependencySet(group: 'io.undertow', version: '2.2.10.Final') {
|
dependencySet(group: 'io.undertow', version: '2.2.12.Final') {
|
||||||
entry 'undertow-core'
|
entry 'undertow-core'
|
||||||
entry('undertow-servlet-jakartaee9')
|
entry('undertow-servlet-jakartaee9') {
|
||||||
entry('undertow-websockets-jsr-jakartaee9')
|
exclude group: "org.jboss.spec.javax.annotation", name: "jboss-annotations-api_1.3_spec"
|
||||||
|
}
|
||||||
|
entry 'undertow-websockets-jsr-jakartaee9'
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencySet(group: 'com.squareup.okhttp3', version: '3.14.9') {
|
dependencySet(group: 'com.squareup.okhttp3', version: '3.14.9') {
|
||||||
|
|
@ -345,7 +347,12 @@ configure([rootProject] + javaProjects) { project ->
|
||||||
"https://hc.apache.org/httpcomponents-client-5.1.x/current/httpclient5/apidocs/",
|
"https://hc.apache.org/httpcomponents-client-5.1.x/current/httpclient5/apidocs/",
|
||||||
"https://projectreactor.io/docs/test/release/api/",
|
"https://projectreactor.io/docs/test/release/api/",
|
||||||
"https://junit.org/junit4/javadoc/4.13.2/",
|
"https://junit.org/junit4/javadoc/4.13.2/",
|
||||||
"https://junit.org/junit5/docs/5.8.1/api/",
|
// TODO Uncomment link to JUnit 5 docs once we have sorted out
|
||||||
|
// the following warning in the build.
|
||||||
|
//
|
||||||
|
// warning: The code being documented uses packages in the unnamed module, but the packages defined in https://junit.org/junit5/docs/5.8.1/api/ are in named modules.
|
||||||
|
//
|
||||||
|
// "https://junit.org/junit5/docs/5.8.1/api/",
|
||||||
"https://www.reactive-streams.org/reactive-streams-1.0.3-javadoc/",
|
"https://www.reactive-streams.org/reactive-streams-1.0.3-javadoc/",
|
||||||
"https://javadoc.io/static/io.rsocket/rsocket-core/1.1.1/",
|
"https://javadoc.io/static/io.rsocket/rsocket-core/1.1.1/",
|
||||||
"https://r2dbc.io/spec/0.8.5.RELEASE/api/"
|
"https://r2dbc.io/spec/0.8.5.RELEASE/api/"
|
||||||
|
|
|
||||||
|
|
@ -46,8 +46,9 @@ task api(type: Javadoc) {
|
||||||
stylesheetFile = file("src/docs/api/stylesheet.css")
|
stylesheetFile = file("src/docs/api/stylesheet.css")
|
||||||
splitIndex = true
|
splitIndex = true
|
||||||
links(project.ext.javadocLinks)
|
links(project.ext.javadocLinks)
|
||||||
addStringOption('Xdoclint:none', '-quiet')
|
addBooleanOption('Xdoclint:syntax', true) // only check syntax with doclint
|
||||||
if(JavaVersion.current().isJava9Compatible()) {
|
addBooleanOption('Werror', true) // fail build on Javadoc warnings
|
||||||
|
if (JavaVersion.current().isJava9Compatible()) {
|
||||||
addBooleanOption('html5', true)
|
addBooleanOption('html5', true)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -25,9 +25,11 @@ import org.springframework.lang.Nullable;
|
||||||
/**
|
/**
|
||||||
* Convenient TargetSourceCreator using bean name prefixes to create one of three
|
* Convenient TargetSourceCreator using bean name prefixes to create one of three
|
||||||
* well-known TargetSource types:
|
* well-known TargetSource types:
|
||||||
* <li>: CommonsPool2TargetSource
|
* <ul>
|
||||||
* <li>% ThreadLocalTargetSource
|
* <li>: CommonsPool2TargetSource</li>
|
||||||
* <li>! PrototypeTargetSource
|
* <li>% ThreadLocalTargetSource</li>
|
||||||
|
* <li>! PrototypeTargetSource</li>
|
||||||
|
* </ul>
|
||||||
*
|
*
|
||||||
* @author Rod Johnson
|
* @author Rod Johnson
|
||||||
* @author Stephane Nicoll
|
* @author Stephane Nicoll
|
||||||
|
|
|
||||||
|
|
@ -540,7 +540,7 @@ public abstract class BeanUtils {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Find a JavaBeans PropertyEditor following the 'Editor' suffix convention
|
* Find a JavaBeans PropertyEditor following the 'Editor' suffix convention
|
||||||
* (e.g. "mypackage.MyDomainClass" -> "mypackage.MyDomainClassEditor").
|
* (e.g. "mypackage.MyDomainClass" → "mypackage.MyDomainClassEditor").
|
||||||
* <p>Compatible to the standard JavaBeans convention as implemented by
|
* <p>Compatible to the standard JavaBeans convention as implemented by
|
||||||
* {@link java.beans.PropertyEditorManager} but isolated from the latter's
|
* {@link java.beans.PropertyEditorManager} but isolated from the latter's
|
||||||
* registered default editors for primitive types.
|
* registered default editors for primitive types.
|
||||||
|
|
|
||||||
|
|
@ -134,8 +134,8 @@ public abstract class PropertyAccessorUtils {
|
||||||
/**
|
/**
|
||||||
* Determine the canonical name for the given property path.
|
* Determine the canonical name for the given property path.
|
||||||
* Removes surrounding quotes from map keys:<br>
|
* Removes surrounding quotes from map keys:<br>
|
||||||
* {@code map['key']} -> {@code map[key]}<br>
|
* {@code map['key']} → {@code map[key]}<br>
|
||||||
* {@code map["key"]} -> {@code map[key]}
|
* {@code map["key"]} → {@code map[key]}
|
||||||
* @param propertyName the bean property path
|
* @param propertyName the bean property path
|
||||||
* @return the canonical representation of the property path
|
* @return the canonical representation of the property path
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -47,17 +47,17 @@ import org.springframework.util.ClassUtils;
|
||||||
* which uses this class to call a static initialization method:
|
* which uses this class to call a static initialization method:
|
||||||
*
|
*
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* <bean id="myObject" class="org.springframework.beans.factory.config.MethodInvokingBean">
|
* <bean id="myObject" class="org.springframework.beans.factory.config.MethodInvokingBean">
|
||||||
* <property name="staticMethod" value="com.whatever.MyClass.init"/>
|
* <property name="staticMethod" value="com.whatever.MyClass.init"/>
|
||||||
* </bean></pre>
|
* </bean></pre>
|
||||||
*
|
*
|
||||||
* <p>An example of calling an instance method to start some server bean:
|
* <p>An example of calling an instance method to start some server bean:
|
||||||
*
|
*
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* <bean id="myStarter" class="org.springframework.beans.factory.config.MethodInvokingBean">
|
* <bean id="myStarter" class="org.springframework.beans.factory.config.MethodInvokingBean">
|
||||||
* <property name="targetObject" ref="myServer"/>
|
* <property name="targetObject" ref="myServer"/>
|
||||||
* <property name="targetMethod" value="start"/>
|
* <property name="targetMethod" value="start"/>
|
||||||
* </bean></pre>
|
* </bean></pre>
|
||||||
*
|
*
|
||||||
* @author Juergen Hoeller
|
* @author Juergen Hoeller
|
||||||
* @since 4.0.3
|
* @since 4.0.3
|
||||||
|
|
|
||||||
|
|
@ -56,24 +56,24 @@ import org.springframework.lang.Nullable;
|
||||||
* which uses this class to call a static factory method:
|
* which uses this class to call a static factory method:
|
||||||
*
|
*
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* <bean id="myObject" class="org.springframework.beans.factory.config.MethodInvokingFactoryBean">
|
* <bean id="myObject" class="org.springframework.beans.factory.config.MethodInvokingFactoryBean">
|
||||||
* <property name="staticMethod" value="com.whatever.MyClassFactory.getInstance"/>
|
* <property name="staticMethod" value="com.whatever.MyClassFactory.getInstance"/>
|
||||||
* </bean></pre>
|
* </bean></pre>
|
||||||
*
|
*
|
||||||
* <p>An example of calling a static method then an instance method to get at a
|
* <p>An example of calling a static method then an instance method to get at a
|
||||||
* Java system property. Somewhat verbose, but it works.
|
* Java system property. Somewhat verbose, but it works.
|
||||||
*
|
*
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* <bean id="sysProps" class="org.springframework.beans.factory.config.MethodInvokingFactoryBean">
|
* <bean id="sysProps" class="org.springframework.beans.factory.config.MethodInvokingFactoryBean">
|
||||||
* <property name="targetClass" value="java.lang.System"/>
|
* <property name="targetClass" value="java.lang.System"/>
|
||||||
* <property name="targetMethod" value="getProperties"/>
|
* <property name="targetMethod" value="getProperties"/>
|
||||||
* </bean>
|
* </bean>
|
||||||
*
|
*
|
||||||
* <bean id="javaVersion" class="org.springframework.beans.factory.config.MethodInvokingFactoryBean">
|
* <bean id="javaVersion" class="org.springframework.beans.factory.config.MethodInvokingFactoryBean">
|
||||||
* <property name="targetObject" ref="sysProps"/>
|
* <property name="targetObject" ref="sysProps"/>
|
||||||
* <property name="targetMethod" value="getProperty"/>
|
* <property name="targetMethod" value="getProperty"/>
|
||||||
* <property name="arguments" value="java.version"/>
|
* <property name="arguments" value="java.version"/>
|
||||||
* </bean></pre>
|
* </bean></pre>
|
||||||
*
|
*
|
||||||
* @author Colin Sampaleanu
|
* @author Colin Sampaleanu
|
||||||
* @author Juergen Hoeller
|
* @author Juergen Hoeller
|
||||||
|
|
|
||||||
|
|
@ -83,22 +83,22 @@ import org.springframework.util.StringUtils;
|
||||||
* <p>A sample config in an XML-based
|
* <p>A sample config in an XML-based
|
||||||
* {@link org.springframework.beans.factory.BeanFactory} might look as follows:
|
* {@link org.springframework.beans.factory.BeanFactory} might look as follows:
|
||||||
*
|
*
|
||||||
* <pre class="code"><beans>
|
* <pre class="code"><beans>
|
||||||
*
|
*
|
||||||
* <!-- Prototype bean since we have state -->
|
* <!-- Prototype bean since we have state -->
|
||||||
* <bean id="myService" class="a.b.c.MyService" singleton="false"/>
|
* <bean id="myService" class="a.b.c.MyService" singleton="false"/>
|
||||||
*
|
*
|
||||||
* <!-- will lookup the above 'myService' bean by *TYPE* -->
|
* <!-- will lookup the above 'myService' bean by *TYPE* -->
|
||||||
* <bean id="myServiceFactory"
|
* <bean id="myServiceFactory"
|
||||||
* class="org.springframework.beans.factory.config.ServiceLocatorFactoryBean">
|
* class="org.springframework.beans.factory.config.ServiceLocatorFactoryBean">
|
||||||
* <property name="serviceLocatorInterface" value="a.b.c.ServiceFactory"/>
|
* <property name="serviceLocatorInterface" value="a.b.c.ServiceFactory"/>
|
||||||
* </bean>
|
* </bean>
|
||||||
*
|
*
|
||||||
* <bean id="clientBean" class="a.b.c.MyClientBean">
|
* <bean id="clientBean" class="a.b.c.MyClientBean">
|
||||||
* <property name="myServiceFactory" ref="myServiceFactory"/>
|
* <property name="myServiceFactory" ref="myServiceFactory"/>
|
||||||
* </bean>
|
* </bean>
|
||||||
*
|
*
|
||||||
*</beans></pre>
|
*</beans></pre>
|
||||||
*
|
*
|
||||||
* <p>The attendant {@code MyClientBean} class implementation might then
|
* <p>The attendant {@code MyClientBean} class implementation might then
|
||||||
* look something like this:
|
* look something like this:
|
||||||
|
|
@ -135,22 +135,22 @@ import org.springframework.util.StringUtils;
|
||||||
* <p>A sample config in an XML-based
|
* <p>A sample config in an XML-based
|
||||||
* {@link org.springframework.beans.factory.BeanFactory} might look as follows:
|
* {@link org.springframework.beans.factory.BeanFactory} might look as follows:
|
||||||
*
|
*
|
||||||
* <pre class="code"><beans>
|
* <pre class="code"><beans>
|
||||||
*
|
*
|
||||||
* <!-- Prototype beans since we have state (both extend MyService) -->
|
* <!-- Prototype beans since we have state (both extend MyService) -->
|
||||||
* <bean id="specialService" class="a.b.c.SpecialService" singleton="false"/>
|
* <bean id="specialService" class="a.b.c.SpecialService" singleton="false"/>
|
||||||
* <bean id="anotherService" class="a.b.c.AnotherService" singleton="false"/>
|
* <bean id="anotherService" class="a.b.c.AnotherService" singleton="false"/>
|
||||||
*
|
*
|
||||||
* <bean id="myServiceFactory"
|
* <bean id="myServiceFactory"
|
||||||
* class="org.springframework.beans.factory.config.ServiceLocatorFactoryBean">
|
* class="org.springframework.beans.factory.config.ServiceLocatorFactoryBean">
|
||||||
* <property name="serviceLocatorInterface" value="a.b.c.ServiceFactory"/>
|
* <property name="serviceLocatorInterface" value="a.b.c.ServiceFactory"/>
|
||||||
* </bean>
|
* </bean>
|
||||||
*
|
*
|
||||||
* <bean id="clientBean" class="a.b.c.MyClientBean">
|
* <bean id="clientBean" class="a.b.c.MyClientBean">
|
||||||
* <property name="myServiceFactory" ref="myServiceFactory"/>
|
* <property name="myServiceFactory" ref="myServiceFactory"/>
|
||||||
* </bean>
|
* </bean>
|
||||||
*
|
*
|
||||||
*</beans></pre>
|
*</beans></pre>
|
||||||
*
|
*
|
||||||
* <p>The attendant {@code MyClientBean} class implementation might then
|
* <p>The attendant {@code MyClientBean} class implementation might then
|
||||||
* look something like this:
|
* look something like this:
|
||||||
|
|
|
||||||
|
|
@ -86,7 +86,7 @@ public abstract class YamlProcessor {
|
||||||
* </pre>
|
* </pre>
|
||||||
* when mapped with
|
* when mapped with
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* setDocumentMatchers(properties ->
|
* setDocumentMatchers(properties ->
|
||||||
* ("prod".equals(properties.getProperty("environment")) ? MatchStatus.FOUND : MatchStatus.NOT_FOUND));
|
* ("prod".equals(properties.getProperty("environment")) ? MatchStatus.FOUND : MatchStatus.NOT_FOUND));
|
||||||
* </pre>
|
* </pre>
|
||||||
* would end up as
|
* would end up as
|
||||||
|
|
|
||||||
|
|
@ -1321,7 +1321,7 @@ public abstract class AbstractAutowireCapableBeanFactory extends AbstractBeanFac
|
||||||
* @param beanName the name of the bean
|
* @param beanName the name of the bean
|
||||||
* @param mbd the bean definition for the bean
|
* @param mbd the bean definition for the bean
|
||||||
* @param explicitArgs argument values passed in programmatically via the getBean method,
|
* @param explicitArgs argument values passed in programmatically via the getBean method,
|
||||||
* or {@code null} if none (-> use constructor argument values from bean definition)
|
* or {@code null} if none (implying the use of constructor argument values from bean definition)
|
||||||
* @return a BeanWrapper for the new instance
|
* @return a BeanWrapper for the new instance
|
||||||
* @see #getBean(String, Object[])
|
* @see #getBean(String, Object[])
|
||||||
*/
|
*/
|
||||||
|
|
@ -1342,7 +1342,7 @@ public abstract class AbstractAutowireCapableBeanFactory extends AbstractBeanFac
|
||||||
* @param mbd the bean definition for the bean
|
* @param mbd the bean definition for the bean
|
||||||
* @param ctors the chosen candidate constructors
|
* @param ctors the chosen candidate constructors
|
||||||
* @param explicitArgs argument values passed in programmatically via the getBean method,
|
* @param explicitArgs argument values passed in programmatically via the getBean method,
|
||||||
* or {@code null} if none (-> use constructor argument values from bean definition)
|
* or {@code null} if none (implying the use of constructor argument values from bean definition)
|
||||||
* @return a BeanWrapper for the new instance
|
* @return a BeanWrapper for the new instance
|
||||||
*/
|
*/
|
||||||
protected BeanWrapper autowireConstructor(
|
protected BeanWrapper autowireConstructor(
|
||||||
|
|
|
||||||
|
|
@ -39,7 +39,7 @@ import org.springframework.util.xml.XmlValidationModeDetector;
|
||||||
* when starting your JVM. For example, to use the Oracle {@link DocumentBuilder},
|
* when starting your JVM. For example, to use the Oracle {@link DocumentBuilder},
|
||||||
* you might start your application like as follows:
|
* you might start your application like as follows:
|
||||||
*
|
*
|
||||||
* <pre code="class">java -Djavax.xml.parsers.DocumentBuilderFactory=oracle.xml.jaxp.JXDocumentBuilderFactory MyMainClass</pre>
|
* <pre class="code">java -Djavax.xml.parsers.DocumentBuilderFactory=oracle.xml.jaxp.JXDocumentBuilderFactory MyMainClass</pre>
|
||||||
*
|
*
|
||||||
* @author Rob Harrop
|
* @author Rob Harrop
|
||||||
* @author Juergen Hoeller
|
* @author Juergen Hoeller
|
||||||
|
|
|
||||||
|
|
@ -71,13 +71,13 @@ public class PluggableSchemaResolver implements EntityResolver {
|
||||||
|
|
||||||
private final String schemaMappingsLocation;
|
private final String schemaMappingsLocation;
|
||||||
|
|
||||||
/** Stores the mapping of schema URL -> local schema path. */
|
/** Stores the mapping of schema URL → local schema path. */
|
||||||
@Nullable
|
@Nullable
|
||||||
private volatile Map<String, String> schemaMappings;
|
private volatile Map<String, String> schemaMappings;
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Loads the schema URL -> schema file location mappings using the default
|
* Loads the schema URL → schema file location mappings using the default
|
||||||
* mapping file pattern "META-INF/spring.schemas".
|
* mapping file pattern "META-INF/spring.schemas".
|
||||||
* @param classLoader the ClassLoader to use for loading
|
* @param classLoader the ClassLoader to use for loading
|
||||||
* (can be {@code null}) to use the default ClassLoader)
|
* (can be {@code null}) to use the default ClassLoader)
|
||||||
|
|
@ -89,7 +89,7 @@ public class PluggableSchemaResolver implements EntityResolver {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Loads the schema URL -> schema file location mappings using the given
|
* Loads the schema URL → schema file location mappings using the given
|
||||||
* mapping file pattern.
|
* mapping file pattern.
|
||||||
* @param classLoader the ClassLoader to use for loading
|
* @param classLoader the ClassLoader to use for loading
|
||||||
* (can be {@code null}) to use the default ClassLoader)
|
* (can be {@code null}) to use the default ClassLoader)
|
||||||
|
|
|
||||||
|
|
@ -896,7 +896,7 @@ public class MimeMessageHelper {
|
||||||
* <p><b>NOTE:</b> Invoke {@code addInline} <i>after</i> {@link #setText};
|
* <p><b>NOTE:</b> Invoke {@code addInline} <i>after</i> {@link #setText};
|
||||||
* else, mail readers might not be able to resolve inline references correctly.
|
* else, mail readers might not be able to resolve inline references correctly.
|
||||||
* @param contentId the content ID to use. Will end up as "Content-ID" header
|
* @param contentId the content ID to use. Will end up as "Content-ID" header
|
||||||
* in the body part, surrounded by angle brackets: e.g. "myId" -> "<myId>".
|
* in the body part, surrounded by angle brackets: e.g. "myId" → "<myId>".
|
||||||
* Can be referenced in HTML source via src="cid:myId" expressions.
|
* Can be referenced in HTML source via src="cid:myId" expressions.
|
||||||
* @param dataSource the {@code jakarta.activation.DataSource} to take
|
* @param dataSource the {@code jakarta.activation.DataSource} to take
|
||||||
* the content from, determining the InputStream and the content type
|
* the content from, determining the InputStream and the content type
|
||||||
|
|
@ -923,7 +923,7 @@ public class MimeMessageHelper {
|
||||||
* <p><b>NOTE:</b> Invoke {@code addInline} <i>after</i> {@link #setText};
|
* <p><b>NOTE:</b> Invoke {@code addInline} <i>after</i> {@link #setText};
|
||||||
* else, mail readers might not be able to resolve inline references correctly.
|
* else, mail readers might not be able to resolve inline references correctly.
|
||||||
* @param contentId the content ID to use. Will end up as "Content-ID" header
|
* @param contentId the content ID to use. Will end up as "Content-ID" header
|
||||||
* in the body part, surrounded by angle brackets: e.g. "myId" -> "<myId>".
|
* in the body part, surrounded by angle brackets: e.g. "myId" → "<myId>".
|
||||||
* Can be referenced in HTML source via src="cid:myId" expressions.
|
* Can be referenced in HTML source via src="cid:myId" expressions.
|
||||||
* @param file the File resource to take the content from
|
* @param file the File resource to take the content from
|
||||||
* @throws MessagingException in case of errors
|
* @throws MessagingException in case of errors
|
||||||
|
|
@ -950,7 +950,7 @@ public class MimeMessageHelper {
|
||||||
* <p><b>NOTE:</b> Invoke {@code addInline} <i>after</i> {@link #setText};
|
* <p><b>NOTE:</b> Invoke {@code addInline} <i>after</i> {@link #setText};
|
||||||
* else, mail readers might not be able to resolve inline references correctly.
|
* else, mail readers might not be able to resolve inline references correctly.
|
||||||
* @param contentId the content ID to use. Will end up as "Content-ID" header
|
* @param contentId the content ID to use. Will end up as "Content-ID" header
|
||||||
* in the body part, surrounded by angle brackets: e.g. "myId" -> "<myId>".
|
* in the body part, surrounded by angle brackets: e.g. "myId" → "<myId>".
|
||||||
* Can be referenced in HTML source via src="cid:myId" expressions.
|
* Can be referenced in HTML source via src="cid:myId" expressions.
|
||||||
* @param resource the resource to take the content from
|
* @param resource the resource to take the content from
|
||||||
* @throws MessagingException in case of errors
|
* @throws MessagingException in case of errors
|
||||||
|
|
@ -976,7 +976,7 @@ public class MimeMessageHelper {
|
||||||
* <p><b>NOTE:</b> Invoke {@code addInline} <i>after</i> {@code setText};
|
* <p><b>NOTE:</b> Invoke {@code addInline} <i>after</i> {@code setText};
|
||||||
* else, mail readers might not be able to resolve inline references correctly.
|
* else, mail readers might not be able to resolve inline references correctly.
|
||||||
* @param contentId the content ID to use. Will end up as "Content-ID" header
|
* @param contentId the content ID to use. Will end up as "Content-ID" header
|
||||||
* in the body part, surrounded by angle brackets: e.g. "myId" -> "<myId>".
|
* in the body part, surrounded by angle brackets: e.g. "myId" → "<myId>".
|
||||||
* Can be referenced in HTML source via src="cid:myId" expressions.
|
* Can be referenced in HTML source via src="cid:myId" expressions.
|
||||||
* @param inputStreamSource the resource to take the content from
|
* @param inputStreamSource the resource to take the content from
|
||||||
* @param contentType the content type to use for the element
|
* @param contentType the content type to use for the element
|
||||||
|
|
|
||||||
|
|
@ -156,7 +156,7 @@ public class AnnotationBeanNameGenerator implements BeanNameGenerator {
|
||||||
/**
|
/**
|
||||||
* Derive a default bean name from the given bean definition.
|
* Derive a default bean name from the given bean definition.
|
||||||
* <p>The default implementation simply builds a decapitalized version
|
* <p>The default implementation simply builds a decapitalized version
|
||||||
* of the short class name: e.g. "mypackage.MyJdbcDao" -> "myJdbcDao".
|
* of the short class name: e.g. "mypackage.MyJdbcDao" → "myJdbcDao".
|
||||||
* <p>Note that inner classes will thus have names of the form
|
* <p>Note that inner classes will thus have names of the form
|
||||||
* "outerClassName.InnerClassName", which because of the period in the
|
* "outerClassName.InnerClassName", which because of the period in the
|
||||||
* name may be an issue if you are autowiring by name.
|
* name may be an issue if you are autowiring by name.
|
||||||
|
|
|
||||||
|
|
@ -315,7 +315,7 @@ public class ReloadableResourceBundleMessageSource extends AbstractResourceBased
|
||||||
/**
|
/**
|
||||||
* Calculate the filenames for the given bundle basename and Locale,
|
* Calculate the filenames for the given bundle basename and Locale,
|
||||||
* appending language code, country code, and variant code.
|
* appending language code, country code, and variant code.
|
||||||
* E.g.: basename "messages", Locale "de_AT_oo" -> "messages_de_AT_OO",
|
* <p>For example, basename "messages", Locale "de_AT_oo" → "messages_de_AT_OO",
|
||||||
* "messages_de_AT", "messages_de".
|
* "messages_de_AT", "messages_de".
|
||||||
* <p>Follows the rules defined by {@link java.util.Locale#toString()}.
|
* <p>Follows the rules defined by {@link java.util.Locale#toString()}.
|
||||||
* @param basename the basename of the bundle
|
* @param basename the basename of the bundle
|
||||||
|
|
|
||||||
|
|
@ -87,7 +87,7 @@ public class ResourceBundleThemeSource implements HierarchicalThemeSource, BeanC
|
||||||
/**
|
/**
|
||||||
* Set the prefix that gets applied to the ResourceBundle basenames,
|
* Set the prefix that gets applied to the ResourceBundle basenames,
|
||||||
* i.e. the theme names.
|
* i.e. the theme names.
|
||||||
* E.g.: basenamePrefix="test.", themeName="theme" -> basename="test.theme".
|
* E.g.: basenamePrefix="test.", themeName="theme" → basename="test.theme".
|
||||||
* <p>Note that ResourceBundle names are effectively classpath locations: As a
|
* <p>Note that ResourceBundle names are effectively classpath locations: As a
|
||||||
* consequence, the JDK's standard ResourceBundle treats dots as package separators.
|
* consequence, the JDK's standard ResourceBundle treats dots as package separators.
|
||||||
* This means that "test.theme" is effectively equivalent to "test/theme",
|
* This means that "test.theme" is effectively equivalent to "test/theme",
|
||||||
|
|
|
||||||
|
|
@ -83,8 +83,8 @@ public interface Errors {
|
||||||
* {@code pushNestedPath(String)} call.
|
* {@code pushNestedPath(String)} call.
|
||||||
* <p>Using the nested path stack allows to set temporary nested paths
|
* <p>Using the nested path stack allows to set temporary nested paths
|
||||||
* for subobjects without having to worry about a temporary path holder.
|
* for subobjects without having to worry about a temporary path holder.
|
||||||
* <p>For example: current path "spouse.", pushNestedPath("child") ->
|
* <p>For example: current path "spouse.", pushNestedPath("child") →
|
||||||
* result path "spouse.child."; popNestedPath() -> "spouse." again.
|
* result path "spouse.child."; popNestedPath() → "spouse." again.
|
||||||
* @param subPath the sub path to push onto the nested path stack
|
* @param subPath the sub path to push onto the nested path stack
|
||||||
* @see #popNestedPath
|
* @see #popNestedPath
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -310,10 +310,10 @@ public class Constants {
|
||||||
* Convert the given bean property name to a constant name prefix.
|
* Convert the given bean property name to a constant name prefix.
|
||||||
* <p>Uses a common naming idiom: turning all lower case characters to
|
* <p>Uses a common naming idiom: turning all lower case characters to
|
||||||
* upper case, and prepending upper case characters with an underscore.
|
* upper case, and prepending upper case characters with an underscore.
|
||||||
* <p>Example: "imageSize" -> "IMAGE_SIZE"<br>
|
* <p>Example: "imageSize" → "IMAGE_SIZE"<br>
|
||||||
* Example: "imagesize" -> "IMAGESIZE".<br>
|
* Example: "imagesize" → "IMAGESIZE".<br>
|
||||||
* Example: "ImageSize" -> "_IMAGE_SIZE".<br>
|
* Example: "ImageSize" → "_IMAGE_SIZE".<br>
|
||||||
* Example: "IMAGESIZE" -> "_I_M_A_G_E_S_I_Z_E"
|
* Example: "IMAGESIZE" → "_I_M_A_G_E_S_I_Z_E"
|
||||||
* @param propertyName the name of the bean property
|
* @param propertyName the name of the bean property
|
||||||
* @return the corresponding constant name prefix
|
* @return the corresponding constant name prefix
|
||||||
* @see #getValuesForProperty
|
* @see #getValuesForProperty
|
||||||
|
|
|
||||||
|
|
@ -91,7 +91,6 @@ public interface SmartClassLoader {
|
||||||
* not being possible (thrown by the default implementation in this interface)
|
* not being possible (thrown by the default implementation in this interface)
|
||||||
* @since 5.3.4
|
* @since 5.3.4
|
||||||
* @see ClassLoader#defineClass(String, byte[], int, int, ProtectionDomain)
|
* @see ClassLoader#defineClass(String, byte[], int, int, ProtectionDomain)
|
||||||
* @see java.lang.invoke.MethodHandles.Lookup#defineClass(byte[])
|
|
||||||
*/
|
*/
|
||||||
default Class<?> publicDefineClass(String name, byte[] b, @Nullable ProtectionDomain protectionDomain) {
|
default Class<?> publicDefineClass(String name, byte[] b, @Nullable ProtectionDomain protectionDomain) {
|
||||||
throw new UnsupportedOperationException();
|
throw new UnsupportedOperationException();
|
||||||
|
|
|
||||||
|
|
@ -70,9 +70,9 @@ public class FileSystemResource extends AbstractResource implements WritableReso
|
||||||
* <p>Note: When building relative resources via {@link #createRelative},
|
* <p>Note: When building relative resources via {@link #createRelative},
|
||||||
* it makes a difference whether the specified resource base path here
|
* it makes a difference whether the specified resource base path here
|
||||||
* ends with a slash or not. In the case of "C:/dir1/", relative paths
|
* ends with a slash or not. In the case of "C:/dir1/", relative paths
|
||||||
* will be built underneath that root: e.g. relative path "dir2" ->
|
* will be built underneath that root: e.g. relative path "dir2" →
|
||||||
* "C:/dir1/dir2". In the case of "C:/dir1", relative paths will apply
|
* "C:/dir1/dir2". In the case of "C:/dir1", relative paths will apply
|
||||||
* at the same directory level: relative path "dir2" -> "C:/dir2".
|
* at the same directory level: relative path "dir2" → "C:/dir2".
|
||||||
* @param path a file path
|
* @param path a file path
|
||||||
* @see #FileSystemResource(Path)
|
* @see #FileSystemResource(Path)
|
||||||
*/
|
*/
|
||||||
|
|
@ -87,7 +87,7 @@ public class FileSystemResource extends AbstractResource implements WritableReso
|
||||||
* Create a new {@code FileSystemResource} from a {@link File} handle.
|
* Create a new {@code FileSystemResource} from a {@link File} handle.
|
||||||
* <p>Note: When building relative resources via {@link #createRelative},
|
* <p>Note: When building relative resources via {@link #createRelative},
|
||||||
* the relative path will apply <i>at the same directory level</i>:
|
* the relative path will apply <i>at the same directory level</i>:
|
||||||
* e.g. new File("C:/dir1"), relative path "dir2" -> "C:/dir2"!
|
* e.g. new File("C:/dir1"), relative path "dir2" → "C:/dir2"!
|
||||||
* If you prefer to have relative paths built underneath the given root directory,
|
* If you prefer to have relative paths built underneath the given root directory,
|
||||||
* use the {@link #FileSystemResource(String) constructor with a file path}
|
* use the {@link #FileSystemResource(String) constructor with a file path}
|
||||||
* to append a trailing slash to the root path: "C:/dir1/", which indicates
|
* to append a trailing slash to the root path: "C:/dir1/", which indicates
|
||||||
|
|
@ -111,7 +111,7 @@ public class FileSystemResource extends AbstractResource implements WritableReso
|
||||||
* path cleaning and {@link #createRelative(String)} handling.
|
* path cleaning and {@link #createRelative(String)} handling.
|
||||||
* <p>Note: When building relative resources via {@link #createRelative},
|
* <p>Note: When building relative resources via {@link #createRelative},
|
||||||
* the relative path will apply <i>at the same directory level</i>:
|
* the relative path will apply <i>at the same directory level</i>:
|
||||||
* e.g. Paths.get("C:/dir1"), relative path "dir2" -> "C:/dir2"!
|
* e.g. Paths.get("C:/dir1"), relative path "dir2" → "C:/dir2"!
|
||||||
* If you prefer to have relative paths built underneath the given root directory,
|
* If you prefer to have relative paths built underneath the given root directory,
|
||||||
* use the {@link #FileSystemResource(String) constructor with a file path}
|
* use the {@link #FileSystemResource(String) constructor with a file path}
|
||||||
* to append a trailing slash to the root path: "C:/dir1/", which indicates
|
* to append a trailing slash to the root path: "C:/dir1/", which indicates
|
||||||
|
|
|
||||||
|
|
@ -64,7 +64,7 @@ public class PathResource extends AbstractResource implements WritableResource {
|
||||||
* Create a new PathResource from a Path handle.
|
* Create a new PathResource from a Path handle.
|
||||||
* <p>Note: Unlike {@link FileSystemResource}, when building relative resources
|
* <p>Note: Unlike {@link FileSystemResource}, when building relative resources
|
||||||
* via {@link #createRelative}, the relative path will be built <i>underneath</i>
|
* via {@link #createRelative}, the relative path will be built <i>underneath</i>
|
||||||
* the given root: e.g. Paths.get("C:/dir1/"), relative path "dir2" -> "C:/dir1/dir2"!
|
* the given root: e.g. Paths.get("C:/dir1/"), relative path "dir2" → "C:/dir1/dir2"!
|
||||||
* @param path a Path handle
|
* @param path a Path handle
|
||||||
*/
|
*/
|
||||||
public PathResource(Path path) {
|
public PathResource(Path path) {
|
||||||
|
|
@ -76,7 +76,7 @@ public class PathResource extends AbstractResource implements WritableResource {
|
||||||
* Create a new PathResource from a Path handle.
|
* Create a new PathResource from a Path handle.
|
||||||
* <p>Note: Unlike {@link FileSystemResource}, when building relative resources
|
* <p>Note: Unlike {@link FileSystemResource}, when building relative resources
|
||||||
* via {@link #createRelative}, the relative path will be built <i>underneath</i>
|
* via {@link #createRelative}, the relative path will be built <i>underneath</i>
|
||||||
* the given root: e.g. Paths.get("C:/dir1/"), relative path "dir2" -> "C:/dir1/dir2"!
|
* the given root: e.g. Paths.get("C:/dir1/"), relative path "dir2" → "C:/dir1/dir2"!
|
||||||
* @param path a path
|
* @param path a path
|
||||||
* @see java.nio.file.Paths#get(String, String...)
|
* @see java.nio.file.Paths#get(String, String...)
|
||||||
*/
|
*/
|
||||||
|
|
@ -89,7 +89,7 @@ public class PathResource extends AbstractResource implements WritableResource {
|
||||||
* Create a new PathResource from a Path handle.
|
* Create a new PathResource from a Path handle.
|
||||||
* <p>Note: Unlike {@link FileSystemResource}, when building relative resources
|
* <p>Note: Unlike {@link FileSystemResource}, when building relative resources
|
||||||
* via {@link #createRelative}, the relative path will be built <i>underneath</i>
|
* via {@link #createRelative}, the relative path will be built <i>underneath</i>
|
||||||
* the given root: e.g. Paths.get("C:/dir1/"), relative path "dir2" -> "C:/dir1/dir2"!
|
* the given root: e.g. Paths.get("C:/dir1/"), relative path "dir2" → "C:/dir1/dir2"!
|
||||||
* @param uri a path URI
|
* @param uri a path URI
|
||||||
* @see java.nio.file.Paths#get(URI)
|
* @see java.nio.file.Paths#get(URI)
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -475,14 +475,14 @@ public class AntPathMatcher implements PathMatcher {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Given a pattern and a full path, determine the pattern-mapped part. <p>For example: <ul>
|
* Given a pattern and a full path, determine the pattern-mapped part. <p>For example: <ul>
|
||||||
* <li>'{@code /docs/cvs/commit.html}' and '{@code /docs/cvs/commit.html} -> ''</li>
|
* <li>'{@code /docs/cvs/commit.html}' and '{@code /docs/cvs/commit.html} → ''</li>
|
||||||
* <li>'{@code /docs/*}' and '{@code /docs/cvs/commit} -> '{@code cvs/commit}'</li>
|
* <li>'{@code /docs/*}' and '{@code /docs/cvs/commit} → '{@code cvs/commit}'</li>
|
||||||
* <li>'{@code /docs/cvs/*.html}' and '{@code /docs/cvs/commit.html} -> '{@code commit.html}'</li>
|
* <li>'{@code /docs/cvs/*.html}' and '{@code /docs/cvs/commit.html} → '{@code commit.html}'</li>
|
||||||
* <li>'{@code /docs/**}' and '{@code /docs/cvs/commit} -> '{@code cvs/commit}'</li>
|
* <li>'{@code /docs/**}' and '{@code /docs/cvs/commit} → '{@code cvs/commit}'</li>
|
||||||
* <li>'{@code /docs/**\/*.html}' and '{@code /docs/cvs/commit.html} -> '{@code cvs/commit.html}'</li>
|
* <li>'{@code /docs/**\/*.html}' and '{@code /docs/cvs/commit.html} → '{@code cvs/commit.html}'</li>
|
||||||
* <li>'{@code /*.html}' and '{@code /docs/cvs/commit.html} -> '{@code docs/cvs/commit.html}'</li>
|
* <li>'{@code /*.html}' and '{@code /docs/cvs/commit.html} → '{@code docs/cvs/commit.html}'</li>
|
||||||
* <li>'{@code *.html}' and '{@code /docs/cvs/commit.html} -> '{@code /docs/cvs/commit.html}'</li>
|
* <li>'{@code *.html}' and '{@code /docs/cvs/commit.html} → '{@code /docs/cvs/commit.html}'</li>
|
||||||
* <li>'{@code *}' and '{@code /docs/cvs/commit.html} -> '{@code /docs/cvs/commit.html}'</li> </ul>
|
* <li>'{@code *}' and '{@code /docs/cvs/commit.html} → '{@code /docs/cvs/commit.html}'</li> </ul>
|
||||||
* <p>Assumes that {@link #match} returns {@code true} for '{@code pattern}' and '{@code path}', but
|
* <p>Assumes that {@link #match} returns {@code true} for '{@code pattern}' and '{@code path}', but
|
||||||
* does <strong>not</strong> enforce this.
|
* does <strong>not</strong> enforce this.
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -43,7 +43,7 @@ import org.springframework.lang.Nullable;
|
||||||
*
|
*
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* Assert.notNull(clazz, "The class must not be null");
|
* Assert.notNull(clazz, "The class must not be null");
|
||||||
* Assert.isTrue(i > 0, "The value must be greater than zero");</pre>
|
* Assert.isTrue(i > 0, "The value must be greater than zero");</pre>
|
||||||
*
|
*
|
||||||
* <p>Mainly for internal use within the framework; for a more comprehensive suite
|
* <p>Mainly for internal use within the framework; for a more comprehensive suite
|
||||||
* of assertion utilities consider {@code org.apache.commons.lang3.Validate} from
|
* of assertion utilities consider {@code org.apache.commons.lang3.Validate} from
|
||||||
|
|
|
||||||
|
|
@ -288,7 +288,7 @@ public class MethodInvoker {
|
||||||
* Algorithm that judges the match between the declared parameter types of a candidate method
|
* Algorithm that judges the match between the declared parameter types of a candidate method
|
||||||
* and a specific list of arguments that this method is supposed to be invoked with.
|
* and a specific list of arguments that this method is supposed to be invoked with.
|
||||||
* <p>Determines a weight that represents the class hierarchy difference between types and
|
* <p>Determines a weight that represents the class hierarchy difference between types and
|
||||||
* arguments. A direct match, i.e. type Integer -> arg of class Integer, does not increase
|
* arguments. A direct match, i.e. type Integer → arg of class Integer, does not increase
|
||||||
* the result - all direct matches means weight 0. A match between type Object and arg of
|
* the result - all direct matches means weight 0. A match between type Object and arg of
|
||||||
* class Integer would increase the weight by 2, due to the superclass 2 steps up in the
|
* class Integer would increase the weight by 2, due to the superclass 2 steps up in the
|
||||||
* hierarchy (i.e. Object) being the last one that still matches the required type Object.
|
* hierarchy (i.e. Object) being the last one that still matches the required type Object.
|
||||||
|
|
|
||||||
|
|
@ -94,7 +94,7 @@ public interface PathMatcher {
|
||||||
* Given a pattern and a full path, extract the URI template variables. URI template
|
* Given a pattern and a full path, extract the URI template variables. URI template
|
||||||
* variables are expressed through curly brackets ('{' and '}').
|
* variables are expressed through curly brackets ('{' and '}').
|
||||||
* <p>For example: For pattern "/hotels/{hotel}" and path "/hotels/1", this method will
|
* <p>For example: For pattern "/hotels/{hotel}" and path "/hotels/1", this method will
|
||||||
* return a map containing "hotel"->"1".
|
* return a map containing "hotel" → "1".
|
||||||
* @param pattern the path pattern, possibly containing URI templates
|
* @param pattern the path pattern, possibly containing URI templates
|
||||||
* @param path the full path to extract template variables from
|
* @param path the full path to extract template variables from
|
||||||
* @return a map, containing variable names as keys; variables values as values
|
* @return a map, containing variable names as keys; variables values as values
|
||||||
|
|
|
||||||
|
|
@ -571,7 +571,7 @@ public abstract class StringUtils {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Extract the filename from the given Java resource path,
|
* Extract the filename from the given Java resource path,
|
||||||
* e.g. {@code "mypath/myfile.txt" -> "myfile.txt"}.
|
* e.g. {@code "mypath/myfile.txt" → "myfile.txt"}.
|
||||||
* @param path the file path (may be {@code null})
|
* @param path the file path (may be {@code null})
|
||||||
* @return the extracted filename, or {@code null} if none
|
* @return the extracted filename, or {@code null} if none
|
||||||
*/
|
*/
|
||||||
|
|
@ -587,7 +587,7 @@ public abstract class StringUtils {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Extract the filename extension from the given Java resource path,
|
* Extract the filename extension from the given Java resource path,
|
||||||
* e.g. "mypath/myfile.txt" -> "txt".
|
* e.g. "mypath/myfile.txt" → "txt".
|
||||||
* @param path the file path (may be {@code null})
|
* @param path the file path (may be {@code null})
|
||||||
* @return the extracted filename extension, or {@code null} if none
|
* @return the extracted filename extension, or {@code null} if none
|
||||||
*/
|
*/
|
||||||
|
|
@ -612,7 +612,7 @@ public abstract class StringUtils {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Strip the filename extension from the given Java resource path,
|
* Strip the filename extension from the given Java resource path,
|
||||||
* e.g. "mypath/myfile.txt" -> "mypath/myfile".
|
* e.g. "mypath/myfile.txt" → "mypath/myfile".
|
||||||
* @param path the file path
|
* @param path the file path
|
||||||
* @return the path with stripped filename extension
|
* @return the path with stripped filename extension
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -81,8 +81,8 @@ public class InvertibleComparator<T> implements Comparator<T>, Serializable {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Invert the sort order: ascending -> descending or
|
* Invert the sort order: ascending → descending or
|
||||||
* descending -> ascending.
|
* descending → ascending.
|
||||||
*/
|
*/
|
||||||
public void invertOrder() {
|
public void invertOrder() {
|
||||||
this.ascending = !this.ascending;
|
this.ascending = !this.ascending;
|
||||||
|
|
|
||||||
|
|
@ -111,7 +111,7 @@ public class LazyConnectionDataSourceProxy extends DelegatingDataSource {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the default auto-commit mode to expose when no target Connection
|
* Set the default auto-commit mode to expose when no target Connection
|
||||||
* has been fetched yet (-> actual JDBC Connection default not known yet).
|
* has been fetched yet (when the actual JDBC Connection default is not known yet).
|
||||||
* <p>If not specified, the default gets determined by checking a target
|
* <p>If not specified, the default gets determined by checking a target
|
||||||
* Connection on startup. If that check fails, the default will be determined
|
* Connection on startup. If that check fails, the default will be determined
|
||||||
* lazily on first access of a Connection.
|
* lazily on first access of a Connection.
|
||||||
|
|
@ -123,7 +123,7 @@ public class LazyConnectionDataSourceProxy extends DelegatingDataSource {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the default transaction isolation level to expose when no target Connection
|
* Set the default transaction isolation level to expose when no target Connection
|
||||||
* has been fetched yet (-> actual JDBC Connection default not known yet).
|
* has been fetched yet (when the actual JDBC Connection default is not known yet).
|
||||||
* <p>This property accepts the int constant value (e.g. 8) as defined in the
|
* <p>This property accepts the int constant value (e.g. 8) as defined in the
|
||||||
* {@link java.sql.Connection} interface; it is mainly intended for programmatic
|
* {@link java.sql.Connection} interface; it is mainly intended for programmatic
|
||||||
* use. Consider using the "defaultTransactionIsolationName" property for setting
|
* use. Consider using the "defaultTransactionIsolationName" property for setting
|
||||||
|
|
|
||||||
|
|
@ -48,7 +48,7 @@ import org.springframework.util.StringUtils;
|
||||||
* <property name="targetDataSource" ref="myTargetDataSource"/>
|
* <property name="targetDataSource" ref="myTargetDataSource"/>
|
||||||
* <property name="username" value="myusername"/>
|
* <property name="username" value="myusername"/>
|
||||||
* <property name="password" value="mypassword"/>
|
* <property name="password" value="mypassword"/>
|
||||||
* </bean></pre>
|
* </bean></pre>
|
||||||
*
|
*
|
||||||
* <p>If the "username" is empty, this proxy will simply delegate to the
|
* <p>If the "username" is empty, this proxy will simply delegate to the
|
||||||
* standard {@code getConnection()} method of the target DataSource.
|
* standard {@code getConnection()} method of the target DataSource.
|
||||||
|
|
|
||||||
|
|
@ -55,7 +55,7 @@ import org.springframework.util.StringUtils;
|
||||||
* <property name="targetConnectionFactory" ref="myTargetConnectionFactory"/>
|
* <property name="targetConnectionFactory" ref="myTargetConnectionFactory"/>
|
||||||
* <property name="username" value="myusername"/>
|
* <property name="username" value="myusername"/>
|
||||||
* <property name="password" value="mypassword"/>
|
* <property name="password" value="mypassword"/>
|
||||||
* </bean></pre>
|
* </bean></pre>
|
||||||
*
|
*
|
||||||
* <p>If the "username" is empty, this proxy will simply delegate to the standard
|
* <p>If the "username" is empty, this proxy will simply delegate to the standard
|
||||||
* {@code createConnection()} method of the target ConnectionFactory.
|
* {@code createConnection()} method of the target ConnectionFactory.
|
||||||
|
|
|
||||||
|
|
@ -32,7 +32,7 @@ import org.springframework.beans.BeanWrapper;
|
||||||
* <p>An ActivationSpec factory is effectively dependent on the concrete
|
* <p>An ActivationSpec factory is effectively dependent on the concrete
|
||||||
* JMS provider, e.g. on ActiveMQ. This default implementation simply
|
* JMS provider, e.g. on ActiveMQ. This default implementation simply
|
||||||
* guesses the ActivationSpec class name from the provider's class name
|
* guesses the ActivationSpec class name from the provider's class name
|
||||||
* ("ActiveMQResourceAdapter" -> "ActiveMQActivationSpec" in the same package,
|
* ("ActiveMQResourceAdapter" → "ActiveMQActivationSpec" in the same package,
|
||||||
* or "ActivationSpecImpl" in the same package as the ResourceAdapter class),
|
* or "ActivationSpecImpl" in the same package as the ResourceAdapter class),
|
||||||
* and populates the ActivationSpec properties as suggested by the
|
* and populates the ActivationSpec properties as suggested by the
|
||||||
* JCA 1.5 specification (Appendix B). Specify the 'activationSpecClass'
|
* JCA 1.5 specification (Appendix B). Specify the 'activationSpecClass'
|
||||||
|
|
@ -67,7 +67,7 @@ public class DefaultJmsActivationSpecFactory extends StandardJmsActivationSpecFa
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* This implementation guesses the ActivationSpec class name from the
|
* This implementation guesses the ActivationSpec class name from the
|
||||||
* provider's class name: e.g. "ActiveMQResourceAdapter" ->
|
* provider's class name: e.g. "ActiveMQResourceAdapter" →
|
||||||
* "ActiveMQActivationSpec" in the same package, or a class named
|
* "ActiveMQActivationSpec" in the same package, or a class named
|
||||||
* "ActivationSpecImpl" in the same package as the ResourceAdapter class.
|
* "ActivationSpecImpl" in the same package as the ResourceAdapter class.
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -104,7 +104,7 @@ public class JmsMessageEndpointManager extends GenericMessageEndpointManager
|
||||||
* {@link #setActivationSpecConfig JmsActivationSpecConfig} objects.
|
* {@link #setActivationSpecConfig JmsActivationSpecConfig} objects.
|
||||||
* <p>This factory is dependent on the concrete JMS provider, e.g. on ActiveMQ.
|
* <p>This factory is dependent on the concrete JMS provider, e.g. on ActiveMQ.
|
||||||
* The default implementation simply guesses the ActivationSpec class name
|
* The default implementation simply guesses the ActivationSpec class name
|
||||||
* from the provider's class name (e.g. "ActiveMQResourceAdapter" ->
|
* from the provider's class name (e.g. "ActiveMQResourceAdapter" →
|
||||||
* "ActiveMQActivationSpec" in the same package), and populates the
|
* "ActiveMQActivationSpec" in the same package), and populates the
|
||||||
* ActivationSpec properties as suggested by the JCA 1.5 specification
|
* ActivationSpec properties as suggested by the JCA 1.5 specification
|
||||||
* (plus a couple of autodetected vendor-specific properties).
|
* (plus a couple of autodetected vendor-specific properties).
|
||||||
|
|
|
||||||
|
|
@ -200,7 +200,7 @@ public class MessageMappingMessageHandler extends AbstractMethodMessageHandler<C
|
||||||
* {@code @ControllerAdvice} bean. You can use the following adapter code
|
* {@code @ControllerAdvice} bean. You can use the following adapter code
|
||||||
* to register {@code @ControllerAdvice} beans here:
|
* to register {@code @ControllerAdvice} beans here:
|
||||||
* <pre>
|
* <pre>
|
||||||
* ControllerAdviceBean.findAnnotatedBeans(context).forEach(bean ->
|
* ControllerAdviceBean.findAnnotatedBeans(context).forEach(bean ->
|
||||||
* messageHandler.registerMessagingAdvice(new ControllerAdviceWrapper(bean));
|
* messageHandler.registerMessagingAdvice(new ControllerAdviceWrapper(bean));
|
||||||
*
|
*
|
||||||
* public class ControllerAdviceWrapper implements MessagingAdviceBean {
|
* public class ControllerAdviceWrapper implements MessagingAdviceBean {
|
||||||
|
|
|
||||||
|
|
@ -461,7 +461,7 @@ public class RSocketMessageHandler extends MessageMappingMessageHandler {
|
||||||
* RSocketMessageHandler.responder(strategies, new ClientHandler());
|
* RSocketMessageHandler.responder(strategies, new ClientHandler());
|
||||||
*
|
*
|
||||||
* RSocketRequester.builder()
|
* RSocketRequester.builder()
|
||||||
* .rsocketConnector(connector -> connector.acceptor(responder))
|
* .rsocketConnector(connector -> connector.acceptor(responder))
|
||||||
* .connectTcp("localhost", server.address().getPort());
|
* .connectTcp("localhost", server.address().getPort());
|
||||||
* </pre>
|
* </pre>
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -46,7 +46,7 @@ import org.springframework.util.ConcurrentReferenceHashMap;
|
||||||
* <bean id="entityManagerFactory" class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean">
|
* <bean id="entityManagerFactory" class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean">
|
||||||
* ...
|
* ...
|
||||||
* <property name="jpaPropertyMap">
|
* <property name="jpaPropertyMap">
|
||||||
* <map>
|
* <map>
|
||||||
* <entry key="hibernate.resource.beans.container">
|
* <entry key="hibernate.resource.beans.container">
|
||||||
* <bean class="org.springframework.orm.hibernate5.SpringBeanContainer"/>
|
* <bean class="org.springframework.orm.hibernate5.SpringBeanContainer"/>
|
||||||
* </entry>
|
* </entry>
|
||||||
|
|
|
||||||
|
|
@ -44,8 +44,8 @@ import org.springframework.util.Assert;
|
||||||
* ConnectionFactory factory = …
|
* ConnectionFactory factory = …
|
||||||
*
|
*
|
||||||
* DatabaseClient client = DatabaseClient.create(factory);
|
* DatabaseClient client = DatabaseClient.create(factory);
|
||||||
* Mono>Actor;lt actor = client.sql("select first_name, last_name from t_actor")
|
* Mono<Actor> actor = client.sql("select first_name, last_name from t_actor")
|
||||||
* .map(row -> new Actor(row.get("first_name, String.class"),
|
* .map(row -> new Actor(row.get("first_name, String.class"),
|
||||||
* row.get("last_name, String.class")))
|
* row.get("last_name, String.class")))
|
||||||
* .first();
|
* .first();
|
||||||
* </pre>
|
* </pre>
|
||||||
|
|
@ -190,7 +190,7 @@ public interface DatabaseClient extends ConnectionAccessor {
|
||||||
* before it is executed. For example:
|
* before it is executed. For example:
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* DatabaseClient client = …;
|
* DatabaseClient client = …;
|
||||||
* client.sql("SELECT book_id FROM book").filter(statement -> statement.fetchSize(100))
|
* client.sql("SELECT book_id FROM book").filter(statement -> statement.fetchSize(100))
|
||||||
* </pre>
|
* </pre>
|
||||||
* @param filterFunction the filter to be added to the chain
|
* @param filterFunction the filter to be added to the chain
|
||||||
*/
|
*/
|
||||||
|
|
@ -205,7 +205,7 @@ public interface DatabaseClient extends ConnectionAccessor {
|
||||||
* before it is executed. For example:
|
* before it is executed. For example:
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* DatabaseClient client = …;
|
* DatabaseClient client = …;
|
||||||
* client.sql("SELECT book_id FROM book").filter((statement, next) -> next.execute(statement.fetchSize(100)))
|
* client.sql("SELECT book_id FROM book").filter((statement, next) -> next.execute(statement.fetchSize(100)))
|
||||||
* </pre>
|
* </pre>
|
||||||
* @param filter the filter to be added to the chain
|
* @param filter the filter to be added to the chain
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -36,7 +36,7 @@ import org.reactivestreams.Publisher;
|
||||||
* For example:
|
* For example:
|
||||||
* <p><pre class="code">
|
* <p><pre class="code">
|
||||||
* DatabaseClient.builder()
|
* DatabaseClient.builder()
|
||||||
* .executeFunction(statement -> statement.execute())
|
* .executeFunction(statement -> statement.execute())
|
||||||
* .build();
|
* .build();
|
||||||
* </pre>
|
* </pre>
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -256,7 +256,7 @@ public abstract class AbstractRequestExpectationManager implements RequestExpect
|
||||||
/**
|
/**
|
||||||
* Invoke this for an expectation that has been matched.
|
* Invoke this for an expectation that has been matched.
|
||||||
* <p>The count of the given expectation is incremented, then it is
|
* <p>The count of the given expectation is incremented, then it is
|
||||||
* either stored if remainingCount > 0 or removed otherwise.
|
* either stored if remainingCount > 0 or removed otherwise.
|
||||||
*/
|
*/
|
||||||
public void update(RequestExpectation expectation) {
|
public void update(RequestExpectation expectation) {
|
||||||
expectation.incrementAndValidate();
|
expectation.incrementAndValidate();
|
||||||
|
|
|
||||||
|
|
@ -80,7 +80,7 @@ public class FluxExchangeResult<T> extends ExchangeResult {
|
||||||
* .exchange()
|
* .exchange()
|
||||||
* .expectStatus().isOk()
|
* .expectStatus().isOk()
|
||||||
* .returnResult()
|
* .returnResult()
|
||||||
* .consumeWith(result -> assertThat(...);
|
* .consumeWith(result -> assertThat(...);
|
||||||
* </pre>
|
* </pre>
|
||||||
* @param consumer the consumer for {@code "this"} instance
|
* @param consumer the consumer for {@code "this"} instance
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -448,15 +448,15 @@ public interface WebTestClient {
|
||||||
* <pre>
|
* <pre>
|
||||||
* client.get().uri("/accounts/1")
|
* client.get().uri("/accounts/1")
|
||||||
* .exchange()
|
* .exchange()
|
||||||
* .expectBody(Person.class).consumeWith(exchangeResult -> ... ));
|
* .expectBody(Person.class).consumeWith(exchangeResult -> ... ));
|
||||||
*
|
*
|
||||||
* client.get().uri("/accounts")
|
* client.get().uri("/accounts")
|
||||||
* .exchange()
|
* .exchange()
|
||||||
* .expectBodyList(Person.class).consumeWith(exchangeResult -> ... ));
|
* .expectBodyList(Person.class).consumeWith(exchangeResult -> ... ));
|
||||||
*
|
*
|
||||||
* client.get().uri("/accounts/1")
|
* client.get().uri("/accounts/1")
|
||||||
* .exchange()
|
* .exchange()
|
||||||
* .expectBody().consumeWith(exchangeResult -> ... ));
|
* .expectBody().consumeWith(exchangeResult -> ... ));
|
||||||
* </pre>
|
* </pre>
|
||||||
* <p>Note that the configured consumer does not apply to responses
|
* <p>Note that the configured consumer does not apply to responses
|
||||||
* decoded to {@code Flux<T>} which can be consumed outside the workflow
|
* decoded to {@code Flux<T>} which can be consumed outside the workflow
|
||||||
|
|
@ -802,8 +802,8 @@ public interface WebTestClient {
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* webTestClient.get().uri("/hello").exchange()
|
* webTestClient.get().uri("/hello").exchange()
|
||||||
* .expectAll(
|
* .expectAll(
|
||||||
* responseSpec -> responseSpec.expectStatus().isOk(),
|
* responseSpec -> responseSpec.expectStatus().isOk(),
|
||||||
* responseSpec -> responseSpec.expectBody(String.class).isEqualTo("Hello, World!")
|
* responseSpec -> responseSpec.expectBody(String.class).isEqualTo("Hello, World!")
|
||||||
* );
|
* );
|
||||||
* </pre>
|
* </pre>
|
||||||
* @param consumers the list of {@code ResponseSpec} consumers
|
* @param consumers the list of {@code ResponseSpec} consumers
|
||||||
|
|
|
||||||
|
|
@ -79,7 +79,7 @@ import org.springframework.transaction.PlatformTransactionManager;
|
||||||
* deriving concrete child bean definitions for specific target objects.
|
* deriving concrete child bean definitions for specific target objects.
|
||||||
* This reduces the per-bean definition effort to a minimum.
|
* This reduces the per-bean definition effort to a minimum.
|
||||||
*
|
*
|
||||||
* <pre code="class">
|
* <pre class="code">
|
||||||
* <bean id="baseTransactionProxy" class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean"
|
* <bean id="baseTransactionProxy" class="org.springframework.transaction.interceptor.TransactionProxyFactoryBean"
|
||||||
* abstract="true">
|
* abstract="true">
|
||||||
* <property name="transactionManager" ref="transactionManager"/>
|
* <property name="transactionManager" ref="transactionManager"/>
|
||||||
|
|
|
||||||
|
|
@ -576,14 +576,13 @@ public final class ContentDisposition {
|
||||||
Builder filename(String filename);
|
Builder filename(String filename);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set the value of the {@literal filename*} that will be encoded as
|
* Set the value of the {@code filename} that will be encoded as
|
||||||
* defined in the RFC 5987. Only the US-ASCII, UTF-8 and ISO-8859-1
|
* defined in RFC 5987. Only the US-ASCII, UTF-8, and ISO-8859-1
|
||||||
* charsets are supported.
|
* charsets are supported.
|
||||||
* <p><strong>Note:</strong> Do not use this for a
|
* <p><strong>Note:</strong> Do not use this for a
|
||||||
* {@code "multipart/form-data"} requests as per
|
* {@code "multipart/form-data"} request since
|
||||||
* <a link="https://tools.ietf.org/html/rfc7578#section-4.2">RFC 7578, Section 4.2</a>
|
* <a href="https://tools.ietf.org/html/rfc7578#section-4.2">RFC 7578, Section 4.2</a>
|
||||||
* and also RFC 5987 itself mentions it does not apply to multipart
|
* and also RFC 5987 mention it does not apply to multipart requests.
|
||||||
* requests.
|
|
||||||
*/
|
*/
|
||||||
Builder filename(String filename, Charset charset);
|
Builder filename(String filename, Charset charset);
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -285,21 +285,21 @@ public enum HttpStatus {
|
||||||
I_AM_A_TEAPOT(418, Series.CLIENT_ERROR, "I'm a teapot"),
|
I_AM_A_TEAPOT(418, Series.CLIENT_ERROR, "I'm a teapot"),
|
||||||
/**
|
/**
|
||||||
* @deprecated See
|
* @deprecated See
|
||||||
* <a href="https://tools.ietf.org/rfcdiff?difftype=--hwdiff{@literal &}url2=draft-ietf-webdav-protocol-06.txt">
|
* <a href="https://tools.ietf.org/rfcdiff?difftype=--hwdiff&url2=draft-ietf-webdav-protocol-06.txt">
|
||||||
* WebDAV Draft Changes</a>
|
* WebDAV Draft Changes</a>
|
||||||
*/
|
*/
|
||||||
@Deprecated
|
@Deprecated
|
||||||
INSUFFICIENT_SPACE_ON_RESOURCE(419, Series.CLIENT_ERROR, "Insufficient Space On Resource"),
|
INSUFFICIENT_SPACE_ON_RESOURCE(419, Series.CLIENT_ERROR, "Insufficient Space On Resource"),
|
||||||
/**
|
/**
|
||||||
* @deprecated See
|
* @deprecated See
|
||||||
* <a href="https://tools.ietf.org/rfcdiff?difftype=--hwdiff{@literal &}url2=draft-ietf-webdav-protocol-06.txt">
|
* <a href="https://tools.ietf.org/rfcdiff?difftype=--hwdiff&url2=draft-ietf-webdav-protocol-06.txt">
|
||||||
* WebDAV Draft Changes</a>
|
* WebDAV Draft Changes</a>
|
||||||
*/
|
*/
|
||||||
@Deprecated
|
@Deprecated
|
||||||
METHOD_FAILURE(420, Series.CLIENT_ERROR, "Method Failure"),
|
METHOD_FAILURE(420, Series.CLIENT_ERROR, "Method Failure"),
|
||||||
/**
|
/**
|
||||||
* @deprecated
|
* @deprecated
|
||||||
* See <a href="https://tools.ietf.org/rfcdiff?difftype=--hwdiff{@literal &}url2=draft-ietf-webdav-protocol-06.txt">
|
* See <a href="https://tools.ietf.org/rfcdiff?difftype=--hwdiff&url2=draft-ietf-webdav-protocol-06.txt">
|
||||||
* WebDAV Draft Changes</a>
|
* WebDAV Draft Changes</a>
|
||||||
*/
|
*/
|
||||||
@Deprecated
|
@Deprecated
|
||||||
|
|
|
||||||
|
|
@ -42,15 +42,15 @@ public interface ClientHttpRequestInterceptor {
|
||||||
* request and response to the next entity in the chain.
|
* request and response to the next entity in the chain.
|
||||||
* <p>A typical implementation of this method would follow the following pattern:
|
* <p>A typical implementation of this method would follow the following pattern:
|
||||||
* <ol>
|
* <ol>
|
||||||
* <li>Examine the {@linkplain HttpRequest request} and body</li>
|
* <li>Examine the {@linkplain HttpRequest request} and body.</li>
|
||||||
* <li>Optionally {@linkplain org.springframework.http.client.support.HttpRequestWrapper
|
* <li>Optionally {@linkplain org.springframework.http.client.support.HttpRequestWrapper
|
||||||
* wrap} the request to filter HTTP attributes.</li>
|
* wrap} the request to filter HTTP attributes.</li>
|
||||||
* <li>Optionally modify the body of the request.</li>
|
* <li>Optionally modify the body of the request.</li>
|
||||||
* <li><strong>Either</strong>
|
|
||||||
* <ul>
|
* <ul>
|
||||||
|
* <li><strong>Either</strong>
|
||||||
* <li>execute the request using
|
* <li>execute the request using
|
||||||
* {@link ClientHttpRequestExecution#execute(org.springframework.http.HttpRequest, byte[])},</li>
|
* {@link ClientHttpRequestExecution#execute(org.springframework.http.HttpRequest, byte[])},</li>
|
||||||
* <strong>or</strong>
|
* <li><strong>or</strong></li>
|
||||||
* <li>do not execute the request to block the execution altogether.</li>
|
* <li>do not execute the request to block the execution altogether.</li>
|
||||||
* </ul>
|
* </ul>
|
||||||
* <li>Optionally wrap the response to filter HTTP attributes.</li>
|
* <li>Optionally wrap the response to filter HTTP attributes.</li>
|
||||||
|
|
|
||||||
|
|
@ -55,7 +55,7 @@ import org.springframework.util.xml.StaxUtils;
|
||||||
* <p>Given the following XML:
|
* <p>Given the following XML:
|
||||||
*
|
*
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* <root>
|
* <root>
|
||||||
* <child>foo</child>
|
* <child>foo</child>
|
||||||
* <child>bar</child>
|
* <child>bar</child>
|
||||||
* </root>
|
* </root>
|
||||||
|
|
|
||||||
|
|
@ -38,11 +38,11 @@ import org.springframework.util.Assert;
|
||||||
* <p>A usage example:
|
* <p>A usage example:
|
||||||
*
|
*
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* <bean class="org.springframework.http.converter.ObjectToStringHttpMessageConverter">
|
* <bean class="org.springframework.http.converter.ObjectToStringHttpMessageConverter">
|
||||||
* <constructor-arg>
|
* <constructor-arg>
|
||||||
* <bean class="org.springframework.context.support.ConversionServiceFactoryBean"/>
|
* <bean class="org.springframework.context.support.ConversionServiceFactoryBean"/>
|
||||||
* </constructor-arg>
|
* </constructor-arg>
|
||||||
* </bean>
|
* </bean>
|
||||||
* </pre>
|
* </pre>
|
||||||
*
|
*
|
||||||
* @author <a href="mailto:dmitry.katsubo@gmail.com">Dmitry Katsubo</a>
|
* @author <a href="mailto:dmitry.katsubo@gmail.com">Dmitry Katsubo</a>
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,7 @@ import org.springframework.http.MediaType;
|
||||||
* that can read and write Atom feeds. Specifically, this converter can handle {@link Feed}
|
* that can read and write Atom feeds. Specifically, this converter can handle {@link Feed}
|
||||||
* objects from the <a href="https://github.com/rometools/rome">ROME</a> project.
|
* objects from the <a href="https://github.com/rometools/rome">ROME</a> project.
|
||||||
*
|
*
|
||||||
* <p>><b>NOTE: As of Spring 4.1, this is based on the {@code com.rometools}
|
* <p><b>NOTE: As of Spring 4.1, this is based on the {@code com.rometools}
|
||||||
* variant of ROME, version 1.5. Please upgrade your build dependency.</b>
|
* variant of ROME, version 1.5. Please upgrade your build dependency.</b>
|
||||||
*
|
*
|
||||||
* <p>By default, this converter reads and writes the media type ({@code application/atom+xml}).
|
* <p>By default, this converter reads and writes the media type ({@code application/atom+xml}).
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,7 @@ import org.springframework.http.MediaType;
|
||||||
* that can read and write RSS feeds. Specifically, this converter can handle {@link Channel}
|
* that can read and write RSS feeds. Specifically, this converter can handle {@link Channel}
|
||||||
* objects from the <a href="https://github.com/rometools/rome">ROME</a> project.
|
* objects from the <a href="https://github.com/rometools/rome">ROME</a> project.
|
||||||
*
|
*
|
||||||
* <p>><b>NOTE: As of Spring 4.1, this is based on the {@code com.rometools}
|
* <p><b>NOTE: As of Spring 4.1, this is based on the {@code com.rometools}
|
||||||
* variant of ROME, version 1.5. Please upgrade your build dependency.</b>
|
* variant of ROME, version 1.5. Please upgrade your build dependency.</b>
|
||||||
*
|
*
|
||||||
* <p>By default, this converter reads and writes the media type ({@code application/rss+xml}).
|
* <p>By default, this converter reads and writes the media type ({@code application/rss+xml}).
|
||||||
|
|
|
||||||
|
|
@ -61,8 +61,8 @@ import org.springframework.util.ReflectionUtils;
|
||||||
*
|
*
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* <absolute-ordering>
|
* <absolute-ordering>
|
||||||
* <name>some_web_fragment</name>
|
* <name>some_web_fragment</name>
|
||||||
* <name>spring_web</name>
|
* <name>spring_web</name>
|
||||||
* </absolute-ordering>
|
* </absolute-ordering>
|
||||||
* </pre>
|
* </pre>
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -36,15 +36,15 @@ import jakarta.servlet.ServletException;
|
||||||
* follows:
|
* follows:
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* <servlet>
|
* <servlet>
|
||||||
* <servlet-name>dispatcher</servlet-name>
|
* <servlet-name>dispatcher</servlet-name>
|
||||||
* <servlet-class>
|
* <servlet-class>
|
||||||
* org.springframework.web.servlet.DispatcherServlet
|
* org.springframework.web.servlet.DispatcherServlet
|
||||||
* </servlet-class>
|
* </servlet-class>
|
||||||
* <init-param>
|
* <init-param>
|
||||||
* <param-name>contextConfigLocation</param-name>
|
* <param-name>contextConfigLocation</param-name>
|
||||||
* <param-value>/WEB-INF/spring/dispatcher-config.xml</param-value>
|
* <param-value>/WEB-INF/spring/dispatcher-config.xml</param-value>
|
||||||
* </init-param>
|
* </init-param>
|
||||||
* <load-on-startup>1</load-on-startup>
|
* <load-on-startup>1</load-on-startup>
|
||||||
* </servlet>
|
* </servlet>
|
||||||
*
|
*
|
||||||
* <servlet-mapping>
|
* <servlet-mapping>
|
||||||
|
|
|
||||||
|
|
@ -36,33 +36,33 @@ import org.springframework.web.jsf.FacesContextUtils;
|
||||||
* <p>Configure this resolver in your {@code faces-config.xml} file as follows:
|
* <p>Configure this resolver in your {@code faces-config.xml} file as follows:
|
||||||
*
|
*
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* <application>
|
* <application>
|
||||||
* ...
|
* ...
|
||||||
* <el-resolver>org.springframework.web.jsf.el.SpringBeanFacesELResolver</el-resolver>
|
* <el-resolver>org.springframework.web.jsf.el.SpringBeanFacesELResolver</el-resolver>
|
||||||
* </application></pre>
|
* </application></pre>
|
||||||
*
|
*
|
||||||
* All your JSF expressions can then implicitly refer to the names of
|
* All your JSF expressions can then implicitly refer to the names of
|
||||||
* Spring-managed service layer beans, for example in property values of
|
* Spring-managed service layer beans, for example in property values of
|
||||||
* JSF-managed beans:
|
* JSF-managed beans:
|
||||||
*
|
*
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* <managed-bean>
|
* <managed-bean>
|
||||||
* <managed-bean-name>myJsfManagedBean</managed-bean-name>
|
* <managed-bean-name>myJsfManagedBean</managed-bean-name>
|
||||||
* <managed-bean-class>example.MyJsfManagedBean</managed-bean-class>
|
* <managed-bean-class>example.MyJsfManagedBean</managed-bean-class>
|
||||||
* <managed-bean-scope>session</managed-bean-scope>
|
* <managed-bean-scope>session</managed-bean-scope>
|
||||||
* <managed-property>
|
* <managed-property>
|
||||||
* <property-name>mySpringManagedBusinessObject</property-name>
|
* <property-name>mySpringManagedBusinessObject</property-name>
|
||||||
* <value>#{mySpringManagedBusinessObject}</value>
|
* <value>#{mySpringManagedBusinessObject}</value>
|
||||||
* </managed-property>
|
* </managed-property>
|
||||||
* </managed-bean></pre>
|
* </managed-bean></pre>
|
||||||
*
|
*
|
||||||
* with "mySpringManagedBusinessObject" defined as Spring bean in
|
* with "mySpringManagedBusinessObject" defined as Spring bean in
|
||||||
* applicationContext.xml:
|
* applicationContext.xml:
|
||||||
*
|
*
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* <bean id="mySpringManagedBusinessObject" class="example.MySpringManagedBusinessObject">
|
* <bean id="mySpringManagedBusinessObject" class="example.MySpringManagedBusinessObject">
|
||||||
* ...
|
* ...
|
||||||
* </bean></pre>
|
* </bean></pre>
|
||||||
*
|
*
|
||||||
* @author Juergen Hoeller
|
* @author Juergen Hoeller
|
||||||
* @since 2.5
|
* @since 2.5
|
||||||
|
|
|
||||||
|
|
@ -44,10 +44,10 @@ import org.springframework.web.jsf.FacesContextUtils;
|
||||||
* <p>Configure this resolver in your {@code faces-config.xml} file as follows:
|
* <p>Configure this resolver in your {@code faces-config.xml} file as follows:
|
||||||
*
|
*
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* <application>
|
* <application>
|
||||||
* ...
|
* ...
|
||||||
* <el-resolver>org.springframework.web.jsf.el.WebApplicationContextFacesELResolver</el-resolver>
|
* <el-resolver>org.springframework.web.jsf.el.WebApplicationContextFacesELResolver</el-resolver>
|
||||||
* </application></pre>
|
* </application></pre>
|
||||||
*
|
*
|
||||||
* @author Juergen Hoeller
|
* @author Juergen Hoeller
|
||||||
* @since 2.5
|
* @since 2.5
|
||||||
|
|
|
||||||
|
|
@ -248,7 +248,7 @@ public interface ServerWebExchange {
|
||||||
* Configure a consumer to modify the current request using a builder.
|
* Configure a consumer to modify the current request using a builder.
|
||||||
* <p>Effectively this:
|
* <p>Effectively this:
|
||||||
* <pre>
|
* <pre>
|
||||||
* exchange.mutate().request(builder-> builder.method(HttpMethod.PUT));
|
* exchange.mutate().request(builder -> builder.method(HttpMethod.PUT));
|
||||||
*
|
*
|
||||||
* // vs...
|
* // vs...
|
||||||
*
|
*
|
||||||
|
|
|
||||||
|
|
@ -289,11 +289,11 @@ public class UrlPathHelper {
|
||||||
* i.e. the part of the request's URL beyond the part that called the servlet,
|
* i.e. the part of the request's URL beyond the part that called the servlet,
|
||||||
* or "" if the whole URL has been used to identify the servlet.
|
* or "" if the whole URL has been used to identify the servlet.
|
||||||
* <p>Detects include request URL if called within a RequestDispatcher include.
|
* <p>Detects include request URL if called within a RequestDispatcher include.
|
||||||
* <p>E.g.: servlet mapping = "/*"; request URI = "/test/a" -> "/test/a".
|
* <p>E.g.: servlet mapping = "/*"; request URI = "/test/a" → "/test/a".
|
||||||
* <p>E.g.: servlet mapping = "/"; request URI = "/test/a" -> "/test/a".
|
* <p>E.g.: servlet mapping = "/"; request URI = "/test/a" → "/test/a".
|
||||||
* <p>E.g.: servlet mapping = "/test/*"; request URI = "/test/a" -> "/a".
|
* <p>E.g.: servlet mapping = "/test/*"; request URI = "/test/a" → "/a".
|
||||||
* <p>E.g.: servlet mapping = "/test"; request URI = "/test" -> "".
|
* <p>E.g.: servlet mapping = "/test"; request URI = "/test" → "".
|
||||||
* <p>E.g.: servlet mapping = "/*.test"; request URI = "/a.test" -> "".
|
* <p>E.g.: servlet mapping = "/*.test"; request URI = "/a.test" → "".
|
||||||
* @param request current HTTP request
|
* @param request current HTTP request
|
||||||
* @param pathWithinApp a precomputed path within the application
|
* @param pathWithinApp a precomputed path within the application
|
||||||
* @return the path within the servlet mapping, or ""
|
* @return the path within the servlet mapping, or ""
|
||||||
|
|
|
||||||
|
|
@ -32,7 +32,7 @@ import reactor.core.publisher.Mono;
|
||||||
*
|
*
|
||||||
* Mono<String> bodyMono = exchangeFunction
|
* Mono<String> bodyMono = exchangeFunction
|
||||||
* .exchange(request)
|
* .exchange(request)
|
||||||
* .flatMap(response -> response.bodyToMono(String.class));
|
* .flatMap(response -> response.bodyToMono(String.class));
|
||||||
* </pre>
|
* </pre>
|
||||||
*
|
*
|
||||||
* @author Arjen Poutsma
|
* @author Arjen Poutsma
|
||||||
|
|
|
||||||
|
|
@ -522,7 +522,7 @@ public interface WebClient {
|
||||||
* Mono<Object> entityMono = client.get()
|
* Mono<Object> entityMono = client.get()
|
||||||
* .uri("/persons/1")
|
* .uri("/persons/1")
|
||||||
* .accept(MediaType.APPLICATION_JSON)
|
* .accept(MediaType.APPLICATION_JSON)
|
||||||
* .exchangeToMono(response -> {
|
* .exchangeToMono(response -> {
|
||||||
* if (response.statusCode().equals(HttpStatus.OK)) {
|
* if (response.statusCode().equals(HttpStatus.OK)) {
|
||||||
* return response.bodyToMono(Person.class);
|
* return response.bodyToMono(Person.class);
|
||||||
* }
|
* }
|
||||||
|
|
@ -554,7 +554,7 @@ public interface WebClient {
|
||||||
* Mono<Object> entityMono = client.get()
|
* Mono<Object> entityMono = client.get()
|
||||||
* .uri("/persons")
|
* .uri("/persons")
|
||||||
* .accept(MediaType.APPLICATION_JSON)
|
* .accept(MediaType.APPLICATION_JSON)
|
||||||
* .exchangeToFlux(response -> {
|
* .exchangeToFlux(response -> {
|
||||||
* if (response.statusCode().equals(HttpStatus.OK)) {
|
* if (response.statusCode().equals(HttpStatus.OK)) {
|
||||||
* return response.bodyToFlux(Person.class);
|
* return response.bodyToFlux(Person.class);
|
||||||
* }
|
* }
|
||||||
|
|
@ -751,7 +751,7 @@ public interface WebClient {
|
||||||
* Provide a function to map specific error status codes to an error
|
* Provide a function to map specific error status codes to an error
|
||||||
* signal to be propagated downstream instead of the response.
|
* signal to be propagated downstream instead of the response.
|
||||||
* <p>By default, if there are no matching status handlers, responses
|
* <p>By default, if there are no matching status handlers, responses
|
||||||
* with status codes >= 400 are mapped to
|
* with status codes >= 400 are mapped to
|
||||||
* {@link WebClientResponseException} which is created with
|
* {@link WebClientResponseException} which is created with
|
||||||
* {@link ClientResponse#createException()}.
|
* {@link ClientResponse#createException()}.
|
||||||
* <p>To suppress the treatment of a status code as an error and process
|
* <p>To suppress the treatment of a status code as an error and process
|
||||||
|
|
@ -766,7 +766,7 @@ public interface WebClient {
|
||||||
* .retrieve()
|
* .retrieve()
|
||||||
* .bodyToMono(Account.class)
|
* .bodyToMono(Account.class)
|
||||||
* .onErrorResume(WebClientResponseException.class,
|
* .onErrorResume(WebClientResponseException.class,
|
||||||
* ex -> ex.getRawStatusCode() == 404 ? Mono.empty() : Mono.error(ex));
|
* ex -> ex.getRawStatusCode() == 404 ? Mono.empty() : Mono.error(ex));
|
||||||
* </pre>
|
* </pre>
|
||||||
* @param statusPredicate to match responses with
|
* @param statusPredicate to match responses with
|
||||||
* @param exceptionFunction to map the response to an error signal
|
* @param exceptionFunction to map the response to an error signal
|
||||||
|
|
|
||||||
|
|
@ -670,7 +670,7 @@ public abstract class RouterFunctions {
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* RouterFunction<ServerResponse> nestedRoute =
|
* RouterFunction<ServerResponse> nestedRoute =
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .nest(RequestPredicates.path("/user"), () ->
|
* .nest(RequestPredicates.path("/user"), () ->
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .GET(this::listUsers)
|
* .GET(this::listUsers)
|
||||||
* .POST(this::createUser)
|
* .POST(this::createUser)
|
||||||
|
|
@ -695,7 +695,7 @@ public abstract class RouterFunctions {
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* RouterFunction<ServerResponse> nestedRoute =
|
* RouterFunction<ServerResponse> nestedRoute =
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .nest(RequestPredicates.path("/user"), builder ->
|
* .nest(RequestPredicates.path("/user"), builder ->
|
||||||
* builder.GET(this::listUsers)
|
* builder.GET(this::listUsers)
|
||||||
* .POST(this::createUser))
|
* .POST(this::createUser))
|
||||||
* .build();
|
* .build();
|
||||||
|
|
@ -740,7 +740,7 @@ public abstract class RouterFunctions {
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* RouterFunction<ServerResponse> nestedRoute =
|
* RouterFunction<ServerResponse> nestedRoute =
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .path("/user", builder ->
|
* .path("/user", builder ->
|
||||||
* builder.GET(this::listUsers)
|
* builder.GET(this::listUsers)
|
||||||
* .POST(this::createUser))
|
* .POST(this::createUser))
|
||||||
* .build();
|
* .build();
|
||||||
|
|
@ -762,7 +762,7 @@ public abstract class RouterFunctions {
|
||||||
* RouterFunction<ServerResponse> filteredRoute =
|
* RouterFunction<ServerResponse> filteredRoute =
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .GET("/user", this::listUsers)
|
* .GET("/user", this::listUsers)
|
||||||
* .filter((request, next) -> {
|
* .filter((request, next) -> {
|
||||||
* // check for authentication headers
|
* // check for authentication headers
|
||||||
* if (isAuthenticated(request)) {
|
* if (isAuthenticated(request)) {
|
||||||
* return next.handle(request);
|
* return next.handle(request);
|
||||||
|
|
@ -788,7 +788,7 @@ public abstract class RouterFunctions {
|
||||||
* RouterFunction<ServerResponse> filteredRoute =
|
* RouterFunction<ServerResponse> filteredRoute =
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .GET("/user", this::listUsers)
|
* .GET("/user", this::listUsers)
|
||||||
* .before(request -> {
|
* .before(request -> {
|
||||||
* log(request);
|
* log(request);
|
||||||
* return request;
|
* return request;
|
||||||
* })
|
* })
|
||||||
|
|
@ -809,7 +809,7 @@ public abstract class RouterFunctions {
|
||||||
* RouterFunction<ServerResponse> filteredRoute =
|
* RouterFunction<ServerResponse> filteredRoute =
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .GET("/user", this::listUsers)
|
* .GET("/user", this::listUsers)
|
||||||
* .after((request, response) -> {
|
* .after((request, response) -> {
|
||||||
* log(response);
|
* log(response);
|
||||||
* return response;
|
* return response;
|
||||||
* })
|
* })
|
||||||
|
|
@ -829,8 +829,8 @@ public abstract class RouterFunctions {
|
||||||
* RouterFunction<ServerResponse> filteredRoute =
|
* RouterFunction<ServerResponse> filteredRoute =
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .GET("/user", this::listUsers)
|
* .GET("/user", this::listUsers)
|
||||||
* .onError(e -> e instanceof IllegalStateException,
|
* .onError(e -> e instanceof IllegalStateException,
|
||||||
* (e, request) -> ServerResponse.status(HttpStatus.INTERNAL_SERVER_ERROR).build())
|
* (e, request) -> ServerResponse.status(HttpStatus.INTERNAL_SERVER_ERROR).build())
|
||||||
* .build();
|
* .build();
|
||||||
* </pre>
|
* </pre>
|
||||||
* @param predicate the type of exception to filter
|
* @param predicate the type of exception to filter
|
||||||
|
|
@ -850,7 +850,7 @@ public abstract class RouterFunctions {
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .GET("/user", this::listUsers)
|
* .GET("/user", this::listUsers)
|
||||||
* .onError(IllegalStateException.class,
|
* .onError(IllegalStateException.class,
|
||||||
* (e, request) -> ServerResponse.status(HttpStatus.INTERNAL_SERVER_ERROR).build())
|
* (e, request) -> ServerResponse.status(HttpStatus.INTERNAL_SERVER_ERROR).build())
|
||||||
* .build();
|
* .build();
|
||||||
* </pre>
|
* </pre>
|
||||||
* @param exceptionType the type of exception to filter
|
* @param exceptionType the type of exception to filter
|
||||||
|
|
|
||||||
|
|
@ -310,7 +310,7 @@ public interface ServerRequest {
|
||||||
* public Mono<ServerResponse> myHandleMethod(ServerRequest request) {
|
* public Mono<ServerResponse> myHandleMethod(ServerRequest request) {
|
||||||
* Instant lastModified = // application-specific calculation
|
* Instant lastModified = // application-specific calculation
|
||||||
* return request.checkNotModified(lastModified)
|
* return request.checkNotModified(lastModified)
|
||||||
* .switchIfEmpty(Mono.defer(() -> {
|
* .switchIfEmpty(Mono.defer(() -> {
|
||||||
* // further request processing, actually building content
|
* // further request processing, actually building content
|
||||||
* return ServerResponse.ok().body(...);
|
* return ServerResponse.ok().body(...);
|
||||||
* }));
|
* }));
|
||||||
|
|
@ -344,7 +344,7 @@ public interface ServerRequest {
|
||||||
* public Mono<ServerResponse> myHandleMethod(ServerRequest request) {
|
* public Mono<ServerResponse> myHandleMethod(ServerRequest request) {
|
||||||
* String eTag = // application-specific calculation
|
* String eTag = // application-specific calculation
|
||||||
* return request.checkNotModified(eTag)
|
* return request.checkNotModified(eTag)
|
||||||
* .switchIfEmpty(Mono.defer(() -> {
|
* .switchIfEmpty(Mono.defer(() -> {
|
||||||
* // further request processing, actually building content
|
* // further request processing, actually building content
|
||||||
* return ServerResponse.ok().body(...);
|
* return ServerResponse.ok().body(...);
|
||||||
* }));
|
* }));
|
||||||
|
|
@ -381,7 +381,7 @@ public interface ServerRequest {
|
||||||
* Instant lastModified = // application-specific calculation
|
* Instant lastModified = // application-specific calculation
|
||||||
* String eTag = // application-specific calculation
|
* String eTag = // application-specific calculation
|
||||||
* return request.checkNotModified(lastModified, eTag)
|
* return request.checkNotModified(lastModified, eTag)
|
||||||
* .switchIfEmpty(Mono.defer(() -> {
|
* .switchIfEmpty(Mono.defer(() -> {
|
||||||
* // further request processing, actually building content
|
* // further request processing, actually building content
|
||||||
* return ServerResponse.ok().body(...);
|
* return ServerResponse.ok().body(...);
|
||||||
* }));
|
* }));
|
||||||
|
|
|
||||||
|
|
@ -45,7 +45,7 @@ import org.springframework.util.PatternMatchUtils;
|
||||||
* specified prefix and/or suffix. Exporting an attribute that holds the
|
* specified prefix and/or suffix. Exporting an attribute that holds the
|
||||||
* RequestContext to all views is explicitly supported.
|
* RequestContext to all views is explicitly supported.
|
||||||
*
|
*
|
||||||
* <p>Example: prefix="templates/", suffix=".ftl", viewname="test" ->
|
* <p>Example: prefix="templates/", suffix=".ftl", viewname="test" →
|
||||||
* "templates/test.ftl"
|
* "templates/test.ftl"
|
||||||
*
|
*
|
||||||
* <p>As a special feature, redirect URLs can be specified via the "redirect:"
|
* <p>As a special feature, redirect URLs can be specified via the "redirect:"
|
||||||
|
|
|
||||||
|
|
@ -45,13 +45,13 @@ import reactor.core.publisher.Mono;
|
||||||
* public Mono<Void> handle(WebSocketSession session) {
|
* public Mono<Void> handle(WebSocketSession session) {
|
||||||
*
|
*
|
||||||
* Flux<WebSocketMessage> output = session.receive()
|
* Flux<WebSocketMessage> output = session.receive()
|
||||||
* .doOnNext(message -> {
|
* .doOnNext(message -> {
|
||||||
* // ...
|
* // ...
|
||||||
* })
|
* })
|
||||||
* .concatMap(message -> {
|
* .concatMap(message -> {
|
||||||
* // ...
|
* // ...
|
||||||
* })
|
* })
|
||||||
* .map(value -> session.textMessage("Echo " + value));
|
* .map(value -> session.textMessage("Echo " + value));
|
||||||
*
|
*
|
||||||
* return session.send(output);
|
* return session.send(output);
|
||||||
* }
|
* }
|
||||||
|
|
@ -68,10 +68,10 @@ import reactor.core.publisher.Mono;
|
||||||
* public Mono<Void> handle(WebSocketSession session) {
|
* public Mono<Void> handle(WebSocketSession session) {
|
||||||
*
|
*
|
||||||
* Mono<Void> input = session.receive()
|
* Mono<Void> input = session.receive()
|
||||||
* .doOnNext(message -> {
|
* .doOnNext(message -> {
|
||||||
* // ...
|
* // ...
|
||||||
* })
|
* })
|
||||||
* .concatMap(message -> {
|
* .concatMap(message -> {
|
||||||
* // ...
|
* // ...
|
||||||
* })
|
* })
|
||||||
* .then();
|
* .then();
|
||||||
|
|
|
||||||
|
|
@ -1266,7 +1266,7 @@ public class DispatcherServlet extends FrameworkServlet {
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* No handler found -> set appropriate HTTP response status.
|
* No handler found → set appropriate HTTP response status.
|
||||||
* @param request current HTTP request
|
* @param request current HTTP request
|
||||||
* @param response current HTTP response
|
* @param response current HTTP response
|
||||||
* @throws Exception if preparing the response failed
|
* @throws Exception if preparing the response failed
|
||||||
|
|
|
||||||
|
|
@ -303,7 +303,7 @@ public class ModelAndView {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Add all attributes contained in the provided Map to the model.
|
* Add all attributes contained in the provided Map to the model.
|
||||||
* @param modelMap a Map of attributeName -> attributeValue pairs
|
* @param modelMap a Map of attributeName → attributeValue pairs
|
||||||
* @see ModelMap#addAllAttributes(Map)
|
* @see ModelMap#addAllAttributes(Map)
|
||||||
* @see #getModelMap()
|
* @see #getModelMap()
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -582,7 +582,7 @@ public abstract class RouterFunctions {
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* RouterFunction<ServerResponse> nestedRoute =
|
* RouterFunction<ServerResponse> nestedRoute =
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .nest(RequestPredicates.path("/user"), () ->
|
* .nest(RequestPredicates.path("/user"), () ->
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .GET(this::listUsers)
|
* .GET(this::listUsers)
|
||||||
* .POST(this::createUser)
|
* .POST(this::createUser)
|
||||||
|
|
@ -607,7 +607,7 @@ public abstract class RouterFunctions {
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* RouterFunction<ServerResponse> nestedRoute =
|
* RouterFunction<ServerResponse> nestedRoute =
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .nest(RequestPredicates.path("/user"), builder ->
|
* .nest(RequestPredicates.path("/user"), builder ->
|
||||||
* builder.GET(this::listUsers)
|
* builder.GET(this::listUsers)
|
||||||
* .POST(this::createUser))
|
* .POST(this::createUser))
|
||||||
* .build();
|
* .build();
|
||||||
|
|
@ -652,7 +652,7 @@ public abstract class RouterFunctions {
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* RouterFunction<ServerResponse> nestedRoute =
|
* RouterFunction<ServerResponse> nestedRoute =
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .path("/user", builder ->
|
* .path("/user", builder ->
|
||||||
* builder.GET(this::listUsers)
|
* builder.GET(this::listUsers)
|
||||||
* .POST(this::createUser))
|
* .POST(this::createUser))
|
||||||
* .build();
|
* .build();
|
||||||
|
|
@ -674,7 +674,7 @@ public abstract class RouterFunctions {
|
||||||
* RouterFunction<ServerResponse> filteredRoute =
|
* RouterFunction<ServerResponse> filteredRoute =
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .GET("/user", this::listUsers)
|
* .GET("/user", this::listUsers)
|
||||||
* .filter((request, next) -> {
|
* .filter((request, next) -> {
|
||||||
* // check for authentication headers
|
* // check for authentication headers
|
||||||
* if (isAuthenticated(request)) {
|
* if (isAuthenticated(request)) {
|
||||||
* return next.handle(request);
|
* return next.handle(request);
|
||||||
|
|
@ -700,7 +700,7 @@ public abstract class RouterFunctions {
|
||||||
* RouterFunction<ServerResponse> filteredRoute =
|
* RouterFunction<ServerResponse> filteredRoute =
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .GET("/user", this::listUsers)
|
* .GET("/user", this::listUsers)
|
||||||
* .before(request -> {
|
* .before(request -> {
|
||||||
* log(request);
|
* log(request);
|
||||||
* return request;
|
* return request;
|
||||||
* })
|
* })
|
||||||
|
|
@ -721,7 +721,7 @@ public abstract class RouterFunctions {
|
||||||
* RouterFunction<ServerResponse> filteredRoute =
|
* RouterFunction<ServerResponse> filteredRoute =
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .GET("/user", this::listUsers)
|
* .GET("/user", this::listUsers)
|
||||||
* .after((request, response) -> {
|
* .after((request, response) -> {
|
||||||
* log(response);
|
* log(response);
|
||||||
* return response;
|
* return response;
|
||||||
* })
|
* })
|
||||||
|
|
@ -741,8 +741,8 @@ public abstract class RouterFunctions {
|
||||||
* RouterFunction<ServerResponse> filteredRoute =
|
* RouterFunction<ServerResponse> filteredRoute =
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .GET("/user", this::listUsers)
|
* .GET("/user", this::listUsers)
|
||||||
* .onError(e -> e instanceof IllegalStateException,
|
* .onError(e -> e instanceof IllegalStateException,
|
||||||
* (e, request) -> ServerResponse.status(HttpStatus.INTERNAL_SERVER_ERROR).build())
|
* (e, request) -> ServerResponse.status(HttpStatus.INTERNAL_SERVER_ERROR).build())
|
||||||
* .build();
|
* .build();
|
||||||
* </pre>
|
* </pre>
|
||||||
* @param predicate the type of exception to filter
|
* @param predicate the type of exception to filter
|
||||||
|
|
@ -762,7 +762,7 @@ public abstract class RouterFunctions {
|
||||||
* RouterFunctions.route()
|
* RouterFunctions.route()
|
||||||
* .GET("/user", this::listUsers)
|
* .GET("/user", this::listUsers)
|
||||||
* .onError(IllegalStateException.class,
|
* .onError(IllegalStateException.class,
|
||||||
* (e, request) -> ServerResponse.status(HttpStatus.INTERNAL_SERVER_ERROR).build())
|
* (e, request) -> ServerResponse.status(HttpStatus.INTERNAL_SERVER_ERROR).build())
|
||||||
* .build();
|
* .build();
|
||||||
* </pre>
|
* </pre>
|
||||||
* @param exceptionType the type of exception to filter
|
* @param exceptionType the type of exception to filter
|
||||||
|
|
|
||||||
|
|
@ -259,7 +259,7 @@ public interface ServerRequest {
|
||||||
* public ServerResponse myHandleMethod(ServerRequest request) {
|
* public ServerResponse myHandleMethod(ServerRequest request) {
|
||||||
* Instant lastModified = // application-specific calculation
|
* Instant lastModified = // application-specific calculation
|
||||||
* return request.checkNotModified(lastModified)
|
* return request.checkNotModified(lastModified)
|
||||||
* .orElseGet(() -> {
|
* .orElseGet(() -> {
|
||||||
* // further request processing, actually building content
|
* // further request processing, actually building content
|
||||||
* return ServerResponse.ok().body(...);
|
* return ServerResponse.ok().body(...);
|
||||||
* });
|
* });
|
||||||
|
|
@ -293,7 +293,7 @@ public interface ServerRequest {
|
||||||
* public ServerResponse myHandleMethod(ServerRequest request) {
|
* public ServerResponse myHandleMethod(ServerRequest request) {
|
||||||
* String eTag = // application-specific calculation
|
* String eTag = // application-specific calculation
|
||||||
* return request.checkNotModified(eTag)
|
* return request.checkNotModified(eTag)
|
||||||
* .orElseGet(() -> {
|
* .orElseGet(() -> {
|
||||||
* // further request processing, actually building content
|
* // further request processing, actually building content
|
||||||
* return ServerResponse.ok().body(...);
|
* return ServerResponse.ok().body(...);
|
||||||
* });
|
* });
|
||||||
|
|
@ -330,7 +330,7 @@ public interface ServerRequest {
|
||||||
* Instant lastModified = // application-specific calculation
|
* Instant lastModified = // application-specific calculation
|
||||||
* String eTag = // application-specific calculation
|
* String eTag = // application-specific calculation
|
||||||
* return request.checkNotModified(lastModified, eTag)
|
* return request.checkNotModified(lastModified, eTag)
|
||||||
* .orElseGet(() -> {
|
* .orElseGet(() -> {
|
||||||
* // further request processing, actually building content
|
* // further request processing, actually building content
|
||||||
* return ServerResponse.ok().body(...);
|
* return ServerResponse.ok().body(...);
|
||||||
* });
|
* });
|
||||||
|
|
|
||||||
|
|
@ -266,14 +266,14 @@ public interface ServerResponse {
|
||||||
* <p>For example:
|
* <p>For example:
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* public ServerResponse handleSse(ServerRequest request) {
|
* public ServerResponse handleSse(ServerRequest request) {
|
||||||
* return ServerResponse.sse(sse -> sse.send("Hello World!"));
|
* return ServerResponse.sse(sse -> sse.send("Hello World!"));
|
||||||
* }
|
* }
|
||||||
* </pre>
|
* </pre>
|
||||||
*
|
*
|
||||||
* <p>or, to set both the id and event type:
|
* <p>or, to set both the id and event type:
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* public ServerResponse handleSse(ServerRequest request) {
|
* public ServerResponse handleSse(ServerRequest request) {
|
||||||
* return ServerResponse.sse(sse -> sse
|
* return ServerResponse.sse(sse -> sse
|
||||||
* .id("42)
|
* .id("42)
|
||||||
* .event("event")
|
* .event("event")
|
||||||
* .send("Hello World!"));
|
* .send("Hello World!"));
|
||||||
|
|
@ -295,14 +295,14 @@ public interface ServerResponse {
|
||||||
* <p>For example:
|
* <p>For example:
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* public ServerResponse handleSse(ServerRequest request) {
|
* public ServerResponse handleSse(ServerRequest request) {
|
||||||
* return ServerResponse.sse(sse -> sse.send("Hello World!"));
|
* return ServerResponse.sse(sse -> sse.send("Hello World!"));
|
||||||
* }
|
* }
|
||||||
* </pre>
|
* </pre>
|
||||||
*
|
*
|
||||||
* <p>or, to set both the id and event type:
|
* <p>or, to set both the id and event type:
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* public ServerResponse handleSse(ServerRequest request) {
|
* public ServerResponse handleSse(ServerRequest request) {
|
||||||
* return ServerResponse.sse(sse -> sse
|
* return ServerResponse.sse(sse -> sse
|
||||||
* .id("42)
|
* .id("42)
|
||||||
* .event("event")
|
* .event("event")
|
||||||
* .send("Hello World!"));
|
* .send("Hello World!"));
|
||||||
|
|
|
||||||
|
|
@ -60,7 +60,6 @@ import org.springframework.web.servlet.handler.AbstractHandlerExceptionResolver;
|
||||||
* <p>This exception resolver is enabled by default in the common Spring
|
* <p>This exception resolver is enabled by default in the common Spring
|
||||||
* {@link org.springframework.web.servlet.DispatcherServlet}.
|
* {@link org.springframework.web.servlet.DispatcherServlet}.
|
||||||
*
|
*
|
||||||
* <p>
|
|
||||||
* <table>
|
* <table>
|
||||||
* <caption>Supported Exceptions</caption>
|
* <caption>Supported Exceptions</caption>
|
||||||
* <thead>
|
* <thead>
|
||||||
|
|
|
||||||
|
|
@ -244,7 +244,7 @@ public abstract class WebContentGenerator extends WebApplicationObjectSupport {
|
||||||
* <ul>
|
* <ul>
|
||||||
* <li>seconds == -1 (default value): no generation cache-related headers</li>
|
* <li>seconds == -1 (default value): no generation cache-related headers</li>
|
||||||
* <li>seconds == 0: "Cache-Control: no-store" will prevent caching</li>
|
* <li>seconds == 0: "Cache-Control: no-store" will prevent caching</li>
|
||||||
* <li>seconds > 0: "Cache-Control: max-age=seconds" will ask to cache content</li>
|
* <li>seconds > 0: "Cache-Control: max-age=seconds" will ask to cache content</li>
|
||||||
* </ul>
|
* </ul>
|
||||||
* <p>For more specific needs, a custom {@link org.springframework.http.CacheControl}
|
* <p>For more specific needs, a custom {@link org.springframework.http.CacheControl}
|
||||||
* should be used.
|
* should be used.
|
||||||
|
|
|
||||||
|
|
@ -51,7 +51,7 @@ import org.springframework.web.util.WebUtils;
|
||||||
* </bean></pre>
|
* </bean></pre>
|
||||||
*
|
*
|
||||||
* Every view name returned from a handler will be translated to a JSP
|
* Every view name returned from a handler will be translated to a JSP
|
||||||
* resource (for example: "myView" -> "/WEB-INF/jsp/myView.jsp"), using
|
* resource (for example: "myView" → "/WEB-INF/jsp/myView.jsp"), using
|
||||||
* this view class by default.
|
* this view class by default.
|
||||||
*
|
*
|
||||||
* @author Rod Johnson
|
* @author Rod Johnson
|
||||||
|
|
|
||||||
|
|
@ -47,7 +47,7 @@ import org.springframework.web.servlet.support.RequestContext;
|
||||||
* </bean></pre>
|
* </bean></pre>
|
||||||
*
|
*
|
||||||
* Every view name returned from a handler will be translated to a JSP
|
* Every view name returned from a handler will be translated to a JSP
|
||||||
* resource (for example: "myView" -> "/WEB-INF/jsp/myView.jsp"), using
|
* resource (for example: "myView" → "/WEB-INF/jsp/myView.jsp"), using
|
||||||
* this view class to enable explicit JSTL support.
|
* this view class to enable explicit JSTL support.
|
||||||
*
|
*
|
||||||
* <p>The specified MessageSource loads messages from "messages.properties" etc
|
* <p>The specified MessageSource loads messages from "messages.properties" etc
|
||||||
|
|
|
||||||
|
|
@ -49,7 +49,7 @@ import org.springframework.web.servlet.View;
|
||||||
* specified prefix and/or suffix. Exporting an attribute that holds the
|
* specified prefix and/or suffix. Exporting an attribute that holds the
|
||||||
* RequestContext to all views is explicitly supported.
|
* RequestContext to all views is explicitly supported.
|
||||||
*
|
*
|
||||||
* <p>Example: prefix="/WEB-INF/jsp/", suffix=".jsp", viewname="test" ->
|
* <p>Example: prefix="/WEB-INF/jsp/", suffix=".jsp", viewname="test" →
|
||||||
* "/WEB-INF/jsp/test.jsp"
|
* "/WEB-INF/jsp/test.jsp"
|
||||||
*
|
*
|
||||||
* <p>As a special feature, redirect URLs can be specified via the "redirect:"
|
* <p>As a special feature, redirect URLs can be specified via the "redirect:"
|
||||||
|
|
@ -342,14 +342,16 @@ public class UrlBasedViewResolver extends AbstractCachingViewResolver implements
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Specify whether views resolved by this resolver should add path variables to the model or not.
|
* Specify whether views resolved by this resolver should add path
|
||||||
* <p>>The default setting is to let each View decide (see {@link AbstractView#setExposePathVariables}.
|
* variables to the model or not.
|
||||||
* However, you can use this property to override that.
|
* <p>The default setting is to let each View decide
|
||||||
|
* (see {@link AbstractView#setExposePathVariables}). However, you
|
||||||
|
* can use this property to override that.
|
||||||
* @param exposePathVariables
|
* @param exposePathVariables
|
||||||
* <ul>
|
* <ul>
|
||||||
* <li>{@code true} - all Views resolved by this resolver will expose path variables
|
* <li>{@code true} - all Views resolved by this resolver will expose path variables
|
||||||
* <li>{@code false} - no Views resolved by this resolver will expose path variables
|
* <li>{@code false} - no Views resolved by this resolver will expose path variables
|
||||||
* <li>{@code null} - individual Views can decide for themselves (this is used by the default)
|
* <li>{@code null} - individual Views can decide for themselves (this is used by default)
|
||||||
* </ul>
|
* </ul>
|
||||||
* @see AbstractView#setExposePathVariables
|
* @see AbstractView#setExposePathVariables
|
||||||
*/
|
*/
|
||||||
|
|
|
||||||
|
|
@ -28,7 +28,7 @@ import jakarta.servlet.http.HttpServletResponse;
|
||||||
* Abstract superclass for Atom Feed views, using the
|
* Abstract superclass for Atom Feed views, using the
|
||||||
* <a href="https://github.com/rometools/rome">ROME</a> package.
|
* <a href="https://github.com/rometools/rome">ROME</a> package.
|
||||||
*
|
*
|
||||||
* <p>><b>NOTE: As of Spring 4.1, this is based on the {@code com.rometools}
|
* <p><b>NOTE: As of Spring 4.1, this is based on the {@code com.rometools}
|
||||||
* variant of ROME, version 1.5. Please upgrade your build dependency.</b>
|
* variant of ROME, version 1.5. Please upgrade your build dependency.</b>
|
||||||
*
|
*
|
||||||
* <p>Application-specific view classes will extend this class.
|
* <p>Application-specific view classes will extend this class.
|
||||||
|
|
|
||||||
|
|
@ -32,7 +32,7 @@ import org.springframework.web.servlet.view.AbstractView;
|
||||||
* Abstract base class for Atom and RSS Feed views, using the
|
* Abstract base class for Atom and RSS Feed views, using the
|
||||||
* <a href="https://github.com/rometools/rome">ROME</a> package.
|
* <a href="https://github.com/rometools/rome">ROME</a> package.
|
||||||
*
|
*
|
||||||
* <p>><b>NOTE: As of Spring 4.1, this is based on the {@code com.rometools}
|
* <p><b>NOTE: As of Spring 4.1, this is based on the {@code com.rometools}
|
||||||
* variant of ROME, version 1.5. Please upgrade your build dependency.</b>
|
* variant of ROME, version 1.5. Please upgrade your build dependency.</b>
|
||||||
*
|
*
|
||||||
* <p>Application-specific view classes will typically extend from either
|
* <p>Application-specific view classes will typically extend from either
|
||||||
|
|
|
||||||
|
|
@ -30,7 +30,7 @@ import org.springframework.http.MediaType;
|
||||||
* Abstract superclass for RSS Feed views, using the
|
* Abstract superclass for RSS Feed views, using the
|
||||||
* <a href="https://github.com/rometools/rome">ROME</a> package.
|
* <a href="https://github.com/rometools/rome">ROME</a> package.
|
||||||
*
|
*
|
||||||
* <p>><b>NOTE: As of Spring 4.1, this is based on the {@code com.rometools}
|
* <p><b>NOTE: As of Spring 4.1, this is based on the {@code com.rometools}
|
||||||
* variant of ROME, version 1.5. Please upgrade your build dependency.</b>
|
* variant of ROME, version 1.5. Please upgrade your build dependency.</b>
|
||||||
*
|
*
|
||||||
* <p>Application-specific view classes will extend this class.
|
* <p>Application-specific view classes will extend this class.
|
||||||
|
|
|
||||||
|
|
@ -38,7 +38,7 @@ import org.springframework.util.Assert;
|
||||||
*
|
*
|
||||||
* <pre class="code">
|
* <pre class="code">
|
||||||
* <bean id="freemarkerConfig" class="org.springframework.web.servlet.view.freemarker.FreeMarkerConfigurer">
|
* <bean id="freemarkerConfig" class="org.springframework.web.servlet.view.freemarker.FreeMarkerConfigurer">
|
||||||
* <property name="templateLoaderPath"><value>/WEB-INF/freemarker/</value></property>
|
* <property name="templateLoaderPath"><value>/WEB-INF/freemarker/</value></property>
|
||||||
* </bean></pre>
|
* </bean></pre>
|
||||||
*
|
*
|
||||||
* This bean must be included in the application context of any application
|
* This bean must be included in the application context of any application
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue