List of usage examples for java.text SimpleDateFormat getDateTimeInstance
public static final DateFormat getDateTimeInstance(int dateStyle, int timeStyle, Locale aLocale)
From source file:org.freeplane.features.format.FormatController.java
private PatternFormat createLocalPattern(String name, int dateStyle, Integer timeStyle) { final SimpleDateFormat simpleDateFormat = (SimpleDateFormat) (timeStyle == null ? SimpleDateFormat.getDateInstance(dateStyle, locale) : SimpleDateFormat.getDateTimeInstance(dateStyle, timeStyle, locale)); final String dStyle = PatternFormat.STYLE_DATE; final String dType = IFormattedObject.TYPE_DATE; return createFormat(simpleDateFormat.toPattern(), dStyle, dType, name, locale); }