java calendar星期_Java正确获取星期Calendar.DAY_OF_WEEK
Calendar now =Calendar.getInstance();//一周第一天是否为星期天boolean isFirstSunday = (now.getFirstDayOfWeek() ==Calendar.SUNDAY);//获取周几int weekDay =now.get(Calendar.DAY_OF_WEEK);//若一周第一天为星期天,则-1if(isFirstSunday)...