Lines Matching refs:month

90 * The cumulative # of days to the end of each month in a non-leap year
114 * The cumulative # of days to the end of each month in a leap year
224 int32_t month = get(UCAL_MONTH, status);
228 acrossAdar1 = (month < ADAR_1); // started before ADAR_1?
229 month += amount;
231 if (acrossAdar1 && month>=ADAR_1 && !isLeapYear(year)) {
232 ++month;
234 if (month <= ELUL) {
237 month -= ELUL+1;
242 acrossAdar1 = (month > ADAR_1); // started after ADAR_1?
243 month += amount;
245 if (acrossAdar1 && month<=ADAR_1 && !isLeapYear(year)) {
246 --month;
248 if (month >= 0) {
251 month += ELUL+1;
256 set(UCAL_MONTH, month);
316 int32_t month = get(UCAL_MONTH, status);
321 int32_t newMonth = month + (amount % yearLength);
323 // If it's not a leap year and we're rolling past the missing month
324 // of ADAR_1, we need to roll an extra month to make up for it.
327 if (amount > 0 && month < ADAR_1 && newMonth >= ADAR_1) {
329 } else if (amount < 0 && month > ADAR_1 && newMonth <= ADAR_1) {
355 // An approximate value for the length of a lunar month.
356 // It is used to calculate the approximate year and month of a given
446 yearLength -= 30; // Subtract length of leap month.
493 * Returns the length of the given month in the given year
496 int32_t HebrewCalendar::handleGetMonthLength(int32_t extendedYear, int32_t month) const {
499 // a 12- or 13-month year (add/subtract 12 or 13, depending
501 // the leap year determines whether or not month 5 (Adar 1)
503 while (month < 0) {
504 month += monthsInYear(--extendedYear);
507 while (month > 12) {
508 month -= monthsInYear(extendedYear++);
511 switch (month) {
514 // These two month lengths can vary
515 return MONTH_LENGTH[month][yearType(extendedYear)];
519 return MONTH_LENGTH[month][0];
571 // Now figure out which month we're in, and the date within that month
575 int32_t month = 0;
577 while (month < momax && dayOfYear > ( isLeap ? LEAP_MONTH_START[month][type] : MONTH_START[month][type] ) ) {
578 month++;
580 if (month >= momax || month<=0) {
585 // the month is in valid range to avoid out of array index
593 month--;
594 int dayOfMonth = dayOfYear - (isLeap ? LEAP_MONTH_START[month][type] : MONTH_START[month][type]);
599 internalSet(UCAL_MONTH, month);
622 * Return JD of start of given month/year.
625 int32_t HebrewCalendar::handleComputeMonthStart(int32_t eyear, int32_t month, UBool /*useMonth*/) const {
629 // a 12- or 13-month year (add/subtract 12 or 13, depending
631 // the leap year determines whether or not month 5 (Adar 1)
633 while (month < 0) {
634 month += monthsInYear(--eyear);
637 while (month > 12) {
638 month -= monthsInYear(eyear++);
647 if (month != 0) {
649 day += LEAP_MONTH_START[month][yearType(eyear)];
651 day += MONTH_START[month][yearType(eyear)];