java获取本地时间格式: GregorianCalendar gregorianCalendar = new GregorianCalendar(); System.out.println(new SimpleDateFormat("yyyy-MM-dd HH:mm:ss EEEE").format(gregorianCalendar.getTime())); 输出: 2011-10-13 15:59:49 星期四