Java Hour Format formateDataC(Date date)

Here you can find the source of formateDataC(Date date)

Description

formate Data C

License

Open Source License

Declaration

public static String formateDataC(Date date) 

Method Source Code


//package com.java2s;

import java.text.SimpleDateFormat;

import java.util.Date;

import java.util.Locale;

public class Main {
    public static final String DATE_FORMAT_D = "EEE, d MMM yyyy HH:mm:ss Z";

    public static String formateDataC(Date date) {
        if (date == null) {
            return null;
        }/* w ww . jav a 2s.  c  o  m*/
        try {
            SimpleDateFormat format = new SimpleDateFormat(DATE_FORMAT_D, Locale.US);
            return format.format(date);
        } catch (Exception e) {
        }
        return null;
    }
}

Related

  1. formatDateToString(java.util.Date date, int format)
  2. formatDebugMessage(String debugLevel, Object msg)
  3. formatDicomTime(String dicomTime)
  4. formatDuration(long duration)
  5. formatDuration(long value)
  6. formateDate(Date date)
  7. formateDate(Date date, String format)
  8. forMateDate(String dateStr)
  9. formateDaTime(Date date)