eleme.openapi.sdk.media.utils.DateUtils Maven / Gradle / Ivy
package eleme.openapi.sdk.media.utils;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Locale;
import java.util.SimpleTimeZone;
/**
* Created by huamulou on 15/12/13.
*/
public class DateUtils {
public static String formatRfc822Date(Date date) {
SimpleDateFormat rfc822DateFormat = new SimpleDateFormat("EEE, dd MMM yyyy HH:mm:ss z", Locale.US);
rfc822DateFormat.setTimeZone(new SimpleTimeZone(0, "GMT"));
return rfc822DateFormat.format(date);
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy