/** * Returns a ISO 8601 representation of the given date. This method * is thread safe and non-blocking. * * @see <a href="https://issues.apache.org/jira/browse/TIKA-495">TIKA-495</a> * @param date given date * @return ISO 8601 date string, including timezone details */ public static String formatDate(Calendar date) { // Explicitly switch it into UTC before formatting date.setTimeZone(UTC); return doFormatDate(date); } /**
/** * Returns a ISO 8601 representation of the given date. This method * is thread safe and non-blocking. * * @see <a href="https://issues.apache.org/jira/browse/TIKA-495">TIKA-495</a> * @param date given date * @return ISO 8601 date string, including timezone details */ public static String formatDate(Date date) { Calendar calendar = GregorianCalendar.getInstance(UTC, Locale.US); calendar.setTime(date); return doFormatDate(calendar); } /**
/** * Returns a ISO 8601 representation of the given date. This method * is thread safe and non-blocking. * * @see <a href="https://issues.apache.org/jira/browse/TIKA-495">TIKA-495</a> * @param date given date * @return ISO 8601 date string, including timezone details */ public static String formatDate(Calendar date) { // Explicitly switch it into UTC before formatting date.setTimeZone(UTC); return doFormatDate(date); } /**
/** * Returns a ISO 8601 representation of the given date. This method * is thread safe and non-blocking. * * @see <a href="https://issues.apache.org/jira/browse/TIKA-495">TIKA-495</a> * @param date given date * @return ISO 8601 date string, including timezone details */ public static String formatDate(Calendar date) { // Explicitly switch it into UTC before formatting date.setTimeZone(UTC); return doFormatDate(date); } /**
/** * Returns a ISO 8601 representation of the given date. This method * is thread safe and non-blocking. * * @see <a href="https://issues.apache.org/jira/browse/TIKA-495">TIKA-495</a> * @param date given date * @return ISO 8601 date string, including timezone details */ public static String formatDate(Date date) { Calendar calendar = GregorianCalendar.getInstance(UTC, Locale.US); calendar.setTime(date); return doFormatDate(calendar); } /**
/** * Returns a ISO 8601 representation of the given date. This method * is thread safe and non-blocking. * * @see <a href="https://issues.apache.org/jira/browse/TIKA-495">TIKA-495</a> * @param date given date * @return ISO 8601 date string, including timezone details */ public static String formatDate(Date date) { Calendar calendar = GregorianCalendar.getInstance(UTC, Locale.US); calendar.setTime(date); return doFormatDate(calendar); } /**