code: public static int getEndValue(Calendar calendar, int dateField) {
  		if(Calendar.DAY_OF_WEEK == dateField) {
  			return (calendar.getFirstDayOfWeek() + 6) % 7;
  		}
  		return calendar.getActualMaximum(dateField);
  	}
docs: 获取指定日期字段的最大值，例如分钟的最小值是59
  
  @param calendar {@link Calendar}
  @param dateField {@link DateField}
  @return 字段最大值
  @since 4.5.7
  @see Calendar#getActualMaximum(int)