List of utility methods to do Time Format
long | getTimeCount(String from, String to, String format) get Time Count Date d1 = dateFormatCheck(from, format); Date d2 = dateFormatCheck(to, format); long duration = d2.getTime() - d1.getTime(); return duration; |
DateFormat | getTimeFormat() get Time Format DateFormat df = new SimpleDateFormat(ISO_8601_DATE_FORMAT); df.setTimeZone(TimeZone.getTimeZone(TIMEZONE_UTC)); return df; |
DateFormat | getTimeFormat() get Time Format if (xldf == null) { xldf = new SimpleDateFormat(); xldf.applyPattern("HH:mm:ss.SSS"); return xldf; |
SimpleDateFormat | getTimeFormat() get Time Format return simpleTimeFormatThreadLocal.get();
|
String | getTimeFormat(Date date, String strFormat) Gets the time format. DateFormat sdf = new SimpleDateFormat(strFormat); String sDate = sdf.format(date); return sDate; |
String | getTimeFormat(java.util.Date date) get Time Format return getFormat(date, TIME_FORMAT_STR);
|
String | getTimeFormat(Locale locale) Returns appropriate time format string. if (locale == null) { locale = Locale.getDefault(); int timeStyle = -1; if (TIME_FORMAT == null || "DEFAULT".equals(TIME_FORMAT) || "SHORT".equals(TIME_FORMAT)) { timeStyle = DateFormat.SHORT; } else if ("MEDIUM".equals(TIME_FORMAT)) { timeStyle = DateFormat.MEDIUM; ... |
SimpleDateFormat | getTimeFormat(String format) get Time Format return new SimpleDateFormat(format); |
String | getTimeFormatted() get Time Formatted return sdf.format(new Date()) + " - "; |
SimpleDateFormat | getTimeFormatter() get Time Formatter return new SimpleDateFormat(TIME_FORMAT); |