摘要:
import java.util.*;int y,m,d,h,mm;Calendar c = Calendar.getInstance();y = c.get(Calendar.YEAR); //年m = c.get(Calendar.MONTH) + 1; //月d = c.get(Calendar.DAY_OF_MONTH); //日h = c.get(Calendar.HOUR); //时(HOUR——十二小时制;HOUR_OF_DAY——二十四小时制)mm = c.get(Calendar.MINUTE); //分2:java.util.Date d = new java.util.D 阅读全文