public static String format(final long number) { return format(number, null); }
this.setLongValue(schema.getConversionPattern() == null ? Long.valueOf(value) : FormatUtils.parseNumber(value, schema.getConversionPattern()).longValue()); } catch (Exception pe) { exception = pe; this.setDoubleValue(schema.getConversionPattern() == null ? Double.valueOf(value) : FormatUtils.parseNumber(value, schema.getConversionPattern()).doubleValue()); } catch (Exception pe) { exception = pe; try { this.setDateValue(schema.getConversionPattern() == null ? FormatUtils.parseDate(value) : new Date(FormatUtils.parseDate(value, schema.getConversionPattern()).getTime())); } catch (Exception pe) { exception = pe;
@Override public void requestDestroyed(final ServletRequestEvent sre) { FormatUtils.clear(); ThreadClassLoaderManager.clearInstance(); CurrentLocale.clear(); } }
case Types.TIMESTAMP: try { parameters[i] = FormatUtils.parseDate(attrs.getValue(i)); } catch (ParseException e) { LOG.error("Unparsable Date '{}'", attrs.getValue(i));
public static String format(final Date date, final boolean lenient) { return format(date, lenient, null); }
public static String format(final double number) { return format(number, null); }
public static String format(final Date date, final boolean lenient) { return format(date, lenient, null); }
public static String format(final Date date) { return format(date, true); }
public static String format(final double number) { return format(number, null); }
public static String format(final Date date) { return format(date, true); }
public static String format(final long number) { return format(number, null); }
final Timestamp timestamp = rs.getTimestamp(columnName); if (timestamp != null) { res = FormatUtils.format(new Date(timestamp.getTime()));
? StringUtils.EMPTY : (fieldType.equals(Date.class) ? FormatUtils.format((Date) fieldValue, false) : fieldValue);
String printed = FormatUtils.format(this.conf.getDateField()); handler.characters(printed.toCharArray(), 0, printed.length()); handler.endElement("", "", "date");
result = schema == null || schema.getConversionPattern() == null ? getLongValue().toString() : FormatUtils.format(getLongValue(), schema.getConversionPattern()); break; result = schema == null || schema.getConversionPattern() == null ? getDoubleValue().toString() : FormatUtils.format(getDoubleValue(), schema.getConversionPattern()); break; ? FormatUtils.format(getDateValue()) : FormatUtils.format(getDateValue(), false, schema.getConversionPattern()); break;
value = any.getCreationDate() == null ? StringUtils.EMPTY : FormatUtils.format(any.getCreationDate()); break; value = User.class.cast(any).getLastLoginDate() == null ? StringUtils.EMPTY : FormatUtils.format(User.class.cast(any).getLastLoginDate()); value = User.class.cast(any).getChangePwdDate() == null ? StringUtils.EMPTY : FormatUtils.format(User.class.cast(any).getChangePwdDate());