Here you can find the source of formatDateUTC(Date d)
public static String formatDateUTC(Date d)
//package com.java2s; // %InstallDIR%\features\org.talend.rcp.branding.%PRODUCTNAME%\%PRODUCTNAME%license.txt import java.text.DateFormat; import java.text.SimpleDateFormat; import java.util.Date; import java.util.TimeZone; public class Main { public static final String ISO8601_DATE_FORMAT = "yyyy-MM-dd'T'HH:mm'Z'"; public static final TimeZone UTC = TimeZone.getTimeZone("UTC"); public static String formatDateUTC(Date d) { return (d != null) ? getISO8601DateFormat().format(d) : "NULL"; }/*w w w . j av a2s . com*/ public static DateFormat getISO8601DateFormat() { DateFormat dateFormat = new SimpleDateFormat(ISO8601_DATE_FORMAT); dateFormat.setTimeZone(UTC); return dateFormat; } }