SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy年MM月dd日 HH小时mm分ss秒");
String format = simpleDateFormat.format(new Date());
System.out.println(format);
1.8 新方法
LocalDateTime dt = LocalDateTime.now();
System.out.println(dt.getYear());
System.out.println(dt.getMonthValue());
System.out.println(dt.getDayOfMonth());
System.out.println(dt.getHour());
System.out.println(dt.getMinute());
System.out.println(dt.getSecond());