日期:2014-05-20 浏览次数:20715 次
Calendar cal = Calendar.getInstance(); System.out.println(cal.get(Calendar.WEEK_OF_YEAR));//返回这一周是这一年的第几周 cal.set(Calendar.WEEK_OF_YEAR, 1);//设置本年有第一周 System.out.println(cal.getTime()); cal.add(Calendar.WEEK_OF_YEAR, 1);//加一周 System.out.println(cal.getTime());//第二周的第一天