@@ -0,0 +1,995 @@
+package com.github.miyasum.sandbox;%0A%0Aimport static java.time.temporal.ChronoField.HOUR_OF_DAY;%0Aimport static java.time.temporal.ChronoField.MINUTE_OF_HOUR;%0Aimport static java.time.temporal.ChronoField.NANO_OF_SECOND;%0Aimport static java.time.temporal.ChronoField.SECOND_OF_MINUTE;%0A%0Aimport java.time.ZonedDateTime;%0Aimport java.time.format.DateTimeFormatter;%0Aimport java.time.format.DateTimeFormatterBuilder;%0A%0A/**%0A * @author MIYASAKA Yasumasa%0A */%0Apublic class DateTimeFormatterSample %7B%0A%0A%09public static void main(String%5B%5D args) %7B%0A%09%09DateTimeFormatter formatter = new DateTimeFormatterBuilder()%0A%09%09%09%09.append(DateTimeFormatter.ISO_LOCAL_DATE)%0A%09%09%09%09.appendLiteral('T')%0A%09%09%09%09.appendValue(HOUR_OF_DAY, 2)%0A%09%09%09%09.appendLiteral(':')%0A%09%09%09%09.appendValue(MINUTE_OF_HOUR, 2)%0A%09%09%09%09.appendLiteral(':')%0A%09%09%09%09.appendValue(SECOND_OF_MINUTE, 2)%0A%09%09%09%09.appendLiteral('.')%0A%09%09%09%09.appendFraction(NANO_OF_SECOND, 6, 6, false)%0A%09%09%09%09.appendOffsetId()%0A%09%09%09%09.toFormatter();%0A%09%09System.out.println(ZonedDateTime.now().format(formatter));%0A%09%7D%0A%7D%0A

Add DateTimeFormatterBuilder sample