/**
* 将String类型时间转换成 年月日 加 星期格式
* @param String time
* @return 星期几 yyyy年MM月dd日格式
*/
public static String dateFormat10(String time) {
Date date = parseToDate(time, "yyyy-MM-dd");
// 创建“简体中文”的Locale
Locale localeCN = Locale.SIMPLIFIED_CHINESE;
SimpleDateFormat format = new SimpleDateFormat("yyyy年MM月dd日 E",localeCN);
String newDate = format.format(date);
return newDate;
}
用Locale对象的中文的环境去格式化日期date!