@ -949,10 +949,8 @@ public class RelativePathUriTemplateController {
@@ -949,10 +949,8 @@ public class RelativePathUriTemplateController {
<para>Handler methods that are annotated with
<classname>@RequestMapping</classname> can have very flexible
signatures. They may have arguments of the following types, in
arbitrary order (except for validation results, which need to follow
right after the corresponding command object, if desired): <!--Reword preceding sentence to clarify, make it a complete sentence and no parentheses: first it says validation results *must*--><!--immediately follow command object, but then it says *if desired*. Clarify what must happen if what is desired. And are validation --><!-- results a type of argument? Relate to the sentence that precedes it.-->
<itemizedlist>
signatures. Most of them can be used in arbitrary order (see below for
more details). <itemizedlist>
<listitem>
<para>Request or response objects (Servlet API). Choose any
specific request or response type, for example
@ -1084,6 +1082,30 @@ public class RelativePathUriTemplateController {
@@ -1084,6 +1082,30 @@ public class RelativePathUriTemplateController {
</listitem>
</itemizedlist></para>
<para>The <interfacename>Errors</interfacename> or
<interfacename>BindingResult</interfacename> parameters have to follow
the model object that is being bound immediately as the method
signature might have more that one model object and Spring will create
a separate <interfacename>BindingResult</interfacename> instance for
each of them so the following sample won't work:</para>
<example>
<title>Invalid ordering of BindingResult and @ModelAttribute</title>