Java Date Format ISO getIso8601DateFormat()

Here you can find the source of getIso8601DateFormat()

Description

get Iso Date Format

License

Apache License

Declaration

private static DateFormat getIso8601DateFormat() 

Method Source Code


//package com.java2s;
//License from project: Apache License 

import java.text.DateFormat;

import java.text.SimpleDateFormat;

import java.util.Locale;
import java.util.SimpleTimeZone;

public class Main {
    private static final String ISO8601_DATE_FORMAT = "yyyy-MM-dd'T'HH:mm:ss.SSS'Z'";

    private static DateFormat getIso8601DateFormat() {
        SimpleDateFormat df = new SimpleDateFormat(ISO8601_DATE_FORMAT, Locale.US);
        df.setTimeZone(new SimpleTimeZone(0, "GMT"));
        return df;
    }/*  w ww . j ava 2 s. co m*/
}

Related

  1. getFormattedMillisolString(double s)
  2. getIso8601(final Date date)
  3. getISO8601Date(final Date date)
  4. getISO8601Date(long millis)
  5. getIso8601DateFormat()
  6. getIso8601DateFormat()
  7. getISO8601DateFormat()
  8. getIso8601DateFormat()
  9. getISO8601DateFormat(TimeZone tz, String mask)