标签:java io ar for div sp 时间 line on
比如把String类型“201104141302” 转换成毫秒数?不胜感激!
import java.text.ParseException;
import java.text.SimpleDateFormat;
public class Cat {
public static void main(String[] args) throws ParseException {
String str = "201104141302";
SimpleDateFormat sdf = new SimpleDateFormat("yyyyMMddhhmm");
long millionSeconds = sdf.parse(str).getTime();//毫秒
System.out.println(millionSeconds);
}
}
标签:java io ar for div sp 时间 line on
原文地址:http://www.cnblogs.com/xgjblog/p/3944584.html