do not register default formatters for Date and Calendar (requiring explicit use of @DateTimeFormat there)

git-svn-id: https://src.springframework.org/svn/spring-framework/trunk@2567 50f2f4bb-b051-0410-bef5-90022cba6387
This commit is contained in:
Juergen Hoeller
2009-12-03 23:26:08 +00:00
parent e0915ad9c6
commit 3f4e30193b
3 changed files with 3 additions and 67 deletions
@@ -111,9 +111,7 @@ public class JodaTimeFormattingConfigurer {
Printer<ReadableInstant> readableInstantPrinter = new ReadableInstantPrinter(jodaDateTimeFormatter);
formatterRegistry.addFormatterForFieldType(ReadableInstant.class, readableInstantPrinter, dateTimeParser);
formatterRegistry.addFormatterForFieldType(Calendar.class, readableInstantPrinter, dateTimeParser);
formatterRegistry.addFormatterForFieldType(Date.class, new MillisecondInstantPrinter(jodaDateTimeFormatter), dateTimeParser);
formatterRegistry.addFormatterForFieldAnnotation(new DateTimeFormatAnnotationFormatterFactory());
}