Java Date Format dateFormat(Date date)

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

Description

Format a Date object into a string format for a day that meets submission report standard.

License

BSD License

Declaration

public static String dateFormat(Date date) 

Method Source Code


//package com.java2s;
/*L//from   w  ww.  java  2 s.  com
 *  Copyright SAIC, Ellumen and RSNA (CTP)
 *
 *
 *  Distributed under the OSI-approved BSD 3-Clause License.
 *  See http://ncip.github.com/national-biomedical-image-archive/LICENSE.txt for details.
 */

import java.text.DateFormat;
import java.text.SimpleDateFormat;

import java.util.Date;

public class Main {
    /**
     * Format a Date object into a string format for a day that
     * meets submission report standard.
     */
    public static String dateFormat(Date date) {
        DateFormat sdf = new SimpleDateFormat("MM/dd/yyyy");
        return sdf.format(date);
    }
}

Related

  1. convertDateToUTC(Date date)
  2. convertDateToXSDString(Date date)
  3. convertDayToString(Date aDate)
  4. dateFmtToString(Date date, SimpleDateFormat fmt)
  5. dateFormat(Date d, String formatStr)
  6. dateFormat(Date date)
  7. dateFormat(Date date)
  8. dateFormat(Date date)
  9. dateFormat(Date date)