List of usage examples for org.apache.commons.lang.time FastDateFormat getInstance
public static FastDateFormat getInstance(String pattern)
Gets a formatter instance using the specified pattern in the default locale.
From source file:de.forsthaus.webui.util.ZksampleDateFormat.java
static public FastDateFormat getDayNumberFormater() { return FastDateFormat.getInstance(Labels.getLabel("format.dayNumber", "dd")); }
From source file:com.kamike.misc.MiscDateUtils.java
public static String getDate(Date now) { return FastDateFormat.getInstance("yyyyMMddHH").format(now); }
From source file:com.zlfun.framework.MiscDateUtils.java
public static String getDate(Date now) { return FastDateFormat.getInstance("yyyy-MM-dd").format(now); }
From source file:com.kamike.misc.MiscDateUtils.java
public static String getDateTime(Date now) { return FastDateFormat.getInstance("yyyy/MM/dd HH:mm:ss").format(now); }
From source file:de.forsthaus.webui.util.ZksampleDateFormat.java
static public FastDateFormat getDaynameFormater() { return FastDateFormat.getInstance(Labels.getLabel("format.dayName", "EEE")); }
From source file:de.forsthaus.webui.util.ZksampleDateFormat.java
static public FastDateFormat getDayMonthFormater() { return FastDateFormat.getInstance(Labels.getLabel("format.DayMonth", "MM/dd")); }
From source file:de.forsthaus.webui.util.ZksampleDateFormat.java
static public FastDateFormat getDateFormater() { return FastDateFormat.getInstance(Labels.getLabel("format.date", "MM.dd.yyyy")); }
From source file:de.forsthaus.webui.util.ZksampleDateFormat.java
static public FastDateFormat getMonth3DigitsFormater() { return FastDateFormat.getInstance(Labels.getLabel("format.month3digits", "MMM")); }
From source file:com.vamonossoftware.core.DateUtil.java
/** * Sets the available patterns.//from ww w . j a v a 2s .c o m */ public static void setPattern(String[] patterns) { activePatterns = patterns; format = FastDateFormat.getInstance(activePatterns[0]); }
From source file:com.nbp.nmp.benefit.common.CommonDataHandleUtil.java
/** * ? ? ? /*from ww w . ja v a 2 s.co m*/ * @param date * @param fromFormatString * @param toFormatString * @return */ public static String stringDateFormatter(String date, String fromFormatString, String toFormatString) { String[] fromParttern = { fromFormatString }; FastDateFormat toFormatter = FastDateFormat.getInstance(toFormatString); Date fromDate = null; try { fromDate = DateUtils.parseDate(date, fromParttern); } catch (Exception e) { return ""; } return toFormatter.format(fromDate); }