[threeten-dev] How to get pattern as a String from DateTimeFormatter

Rodrigo Uchôa rodrigo.uchoa at gmail.com
Mon Mar 2 18:50:36 UTC 2015


After building an instance of DateTimeFormatter, is it possible to extract
from it the pattern as a String?

Something like this:

DateTimeFormatter formatter = DateTimeFormatter.ofPattern("MM/dd/yyyy");
String pattern = formatter.toPattern(); //example

Is there any way this can done?

Regards!


More information about the threeten-dev mailing list