Here you can find the source of dateToString(Date date)
public static String dateToString(Date date)
//package com.java2s; import java.text.SimpleDateFormat; import java.util.Date; import java.util.Locale; public class Main { public static final Locale LOCAL_ES = new Locale("es", "ES"); public static final String FORMAT_PATTERN = "MMMMM d, yyyy"; public static String dateToString(Date date) { return (new SimpleDateFormat(FORMAT_PATTERN, LOCAL_ES)).format(date); }//w ww . ja v a2 s. c o m public static String dateToString(Date date, String pattern) { return (new SimpleDateFormat(pattern, LOCAL_ES)).format(date); } }