@SuppressWarnings("unused")
  public static String rfcDateTime(final Date val, final TimeZone tz) {
    synchronized (rfcDateTimeTZFormat) {
      rfcDateTimeTZFormat.setTimeZone(tz);
      return rfcDateTimeTZFormat.format(val);
    }
  }
@ SuppressWarnings ( "unused" ) public static String rfcDateTime ( final Date val , final TimeZone tz ) { synchronized ( rfcDateTimeTZFormat ) { rfcDateTimeTZFormat . setTimeZone ( tz ) ; return rfcDateTimeTZFormat . format ( val ) ; } }
Turn Date into "yyyy-MM-ddTHH:mm:ss" for a given timezone

@param val date
@param tz TimeZone
@return String "yyyy-MM-ddTHH:mm:ss"