Android examples for java.util:Date Format
format Date to string in d MMMM yyyy format
import java.text.ParseException; import java.text.SimpleDateFormat; import java.util.Date; import java.util.Locale; import java.util.regex.Matcher; import java.util.regex.Pattern; public class Main{ private static SimpleDateFormat FORMATTER = new SimpleDateFormat( "d MMMM yyyy"); public static String formatDate(Date date) { return FORMATTER.format(date); }/*from www .ja va 2 s . c o m*/ }