PointInTimeFormat { public static DateTimeFormatter date() { if (d == null) { d = forPattern(DEFAULT_DATE_PATTERN); } return d; } protected  PointInTimeFormat(); static DateTimeFormatter forPattern(String pattern); static DateTimeFormatter date(); static DateTimeFormatter dateTime(); static DateTimeFormatter time(); static DateTimeFormatter year(); static DateTimeFormatter monthAndYear(); static DateTimeFormatter forPointInTime(PointInTime t); static DateTimeFormatter forPrecision(Precision p);  }
@Test public void testDefaultDateFormat() { PointInTime t = new PointInTime(1975, 7, 23); Assert.assertEquals("Jul 23,75", PointInTimeFormat.date().print(t)); LocalDateTime ldt = new LocalDateTime(1975, 7, 23, 10, 23); Assert.assertEquals("Jul 23,75", PointInTimeFormat.date().print(ldt)); DateTime dt = new DateTime(1975, 7, 23, 10, 23, 55, 0); Assert.assertEquals("Jul 23,75", PointInTimeFormat.date().print(dt)); }