标签:simple except java se lib font 时间 mat imp ted
package config;
import Java.text.DateFormat;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
public class Test {
public static void main(String[] args) {
String s="Mon Mar 30 00:00:00 CST 2015";
Date f = new Date(s);
try {
String c = new SimpleDateFormat("yyyy-MM-dd").format(f);
System.out.println(c);
} catch (Exception e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
}
}
java中Thursday 05 September 2002类型时间的转化
标签:simple except java se lib font 时间 mat imp ted
原文地址:http://www.cnblogs.com/nangonghui/p/6824016.html