Polish reference documentation

`@InitBinder` annotated methods are not meant to be part of the public
contract of Controller and should be package protected.
This commit is contained in:
Brian Clozel 2016-04-08 16:47:11 +02:00
parent e365ffb67a
commit f3b09464f3
2 changed files with 4 additions and 4 deletions

View File

@ -2039,7 +2039,7 @@ The following example demonstrates the use of `@InitBinder` to configure a
public class MyFormController {
**@InitBinder**
public void initBinder(WebDataBinder binder) {
protected void initBinder(WebDataBinder binder) {
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");
dateFormat.setLenient(false);
binder.registerCustomEditor(Date.class, new CustomDateEditor(dateFormat, false));
@ -2062,7 +2062,7 @@ controller-specific tweaking of the binding rules.
public class MyFormController {
**@InitBinder**
public void initBinder(WebDataBinder binder) {
protected void initBinder(WebDataBinder binder) {
binder.addCustomFormatter(new DateFormatter("yyyy-MM-dd"));
}

View File

@ -1462,8 +1462,8 @@ The following example demonstrates the use of `@InitBinder` for configuring a
public class MyFormController {
@InitBinder
public void initBinder(WebDataBinder binder) {
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");
protected void initBinder(WebDataBinder binder) {
SimpleDateFormat dateFormat = new SimpleDateFormat("yyyy-MM-dd");
dateFormat.setLenient(false);
binder.registerCustomEditor(Date.class, new CustomDateEditor(dateFormat, false));
}