时间函数相关处理
获取当前的系统时间
Timestamp a = new Timestamp(System.currentTimeMillis());
Date date = new Date(a.getTime());
System.out.println(a);
// 2019-10-26 17:02:28.998
System.out.println(date);
// Sat Oct 26 17:12:04 CST 2019
时间比较
Timestamp a = Timestamp.valueOf("2010-01-01 00:00:00");
Timestamp b = new Timestamp(System.currentTimeMillis());
boolean c = a.before(b);
// true;
boolen d = a.after(b);
// false