/libcore/ojluni/src/test/java/time/tck/java/time/temporal/ |
D | TCKTemporalAdjusters.java | 112 for (Month month : Month.values()) { in test_firstDayOfMonth_nonLeap() 113 for (int i = 1; i <= month.length(false); i++) { in test_firstDayOfMonth_nonLeap() 114 LocalDate date = date(2007, month, i); in test_firstDayOfMonth_nonLeap() 117 assertEquals(test.getMonth(), month); in test_firstDayOfMonth_nonLeap() local 125 for (Month month : Month.values()) { in test_firstDayOfMonth_leap() 126 for (int i = 1; i <= month.length(true); i++) { in test_firstDayOfMonth_leap() 127 LocalDate date = date(2008, month, i); in test_firstDayOfMonth_leap() 130 assertEquals(test.getMonth(), month); in test_firstDayOfMonth_leap() local 146 for (Month month : Month.values()) { in test_lastDayOfMonth_nonLeap() 147 for (int i = 1; i <= month.length(false); i++) { in test_lastDayOfMonth_nonLeap() [all …]
|
/libcore/ojluni/src/main/java/java/time/ |
D | MonthDay.java | 141 private final int month; field in MonthDay 211 public static MonthDay of(Month month, int dayOfMonth) { in of() argument 212 Objects.requireNonNull(month, "month"); in of() 214 if (dayOfMonth > month.maxLength()) { in of() 216 " is not valid for month " + month.name()); in of() 218 return new MonthDay(month.getValue(), dayOfMonth); in of() 237 public static MonthDay of(int month, int dayOfMonth) { in of() argument 238 return of(Month.of(month), dayOfMonth); in of() 313 private MonthDay(int month, int dayOfMonth) { in MonthDay() argument 314 this.month = month; in MonthDay() [all …]
|
D | YearMonth.java | 148 private final int month; field in YearMonth 206 public static YearMonth of(int year, Month month) { in of() argument 207 Objects.requireNonNull(month, "month"); in of() 208 return of(year, month.getValue()); in of() 219 public static YearMonth of(int year, int month) { in of() argument 221 MONTH_OF_YEAR.checkValidValue(month); in of() 222 return new YearMonth(year, month); in of() 299 private YearMonth(int year, int month) { in YearMonth() argument 301 this.month = month; in YearMonth() 313 if (year == newYear && month == newMonth) { in with() [all …]
|
D | LocalDate.java | 167 private final short month; field in LocalDate 239 public static LocalDate of(int year, Month month, int dayOfMonth) { in of() argument 241 Objects.requireNonNull(month, "month"); in of() 243 return create(year, month.getValue(), dayOfMonth); in of() 259 public static LocalDate of(int year, int month, int dayOfMonth) { in of() argument 261 MONTH_OF_YEAR.checkValidValue(month); in of() 263 return create(year, month, dayOfMonth); in of() 330 int month = (marchMonth0 + 2) % 12 + 1; in ofEpochDay() local 336 return new LocalDate(year, month, dom); in ofEpochDay() 407 private static LocalDate create(int year, int month, int dayOfMonth) { in create() argument [all …]
|
D | Month.java | 185 public static Month of(int month) { in of() argument 186 if (month < 1 || month > 12) { in of() 187 throw new DateTimeException("Invalid value for MonthOfYear: " + month); in of() 189 return ENUMS[month - 1]; in of()
|
D | LocalDateTime.java | 229 public static LocalDateTime of(int year, Month month, int dayOfMonth, int hour, int minute) { in of() argument 230 LocalDate date = LocalDate.of(year, month, dayOfMonth); in of() 254 …public static LocalDateTime of(int year, Month month, int dayOfMonth, int hour, int minute, int se… in of() argument 255 LocalDate date = LocalDate.of(year, month, dayOfMonth); in of() 279 …public static LocalDateTime of(int year, Month month, int dayOfMonth, int hour, int minute, int se… in of() argument 280 LocalDate date = LocalDate.of(year, month, dayOfMonth); in of() 304 public static LocalDateTime of(int year, int month, int dayOfMonth, int hour, int minute) { in of() argument 305 LocalDate date = LocalDate.of(year, month, dayOfMonth); in of() 329 …public static LocalDateTime of(int year, int month, int dayOfMonth, int hour, int minute, int seco… in of() argument 330 LocalDate date = LocalDate.of(year, month, dayOfMonth); in of() [all …]
|
/libcore/ojluni/src/main/java/sun/util/calendar/ |
D | BaseCalendar.java | 151 public Date setNormalizedDate(int normalizedYear, int month, int dayOfMonth) { in setNormalizedDate() argument 153 setMonth(month).setDayOfMonth(dayOfMonth); in setNormalizedDate() 196 int month = bdate.getMonth(); in validate() local 197 if (month < JANUARY || month > DECEMBER) { in validate() 201 if (d <= 0 || d > getMonthLength(bdate.getNormalizedYear(), month)) { in validate() 275 long month = bdate.getMonth(); in normalizeMonth() local 276 if (month <= 0) { in normalizeMonth() 277 long xm = 1L - month; in normalizeMonth() 279 month = 13 - (xm % 12); in normalizeMonth() 281 bdate.setMonth((int) month); in normalizeMonth() [all …]
|
D | JulianCalendar.java | 148 public long getFixedDate(int jyear, int month, int dayOfMonth, BaseCalendar.Date cache) { in getFixedDate() argument 149 boolean isJan1 = month == JANUARY && dayOfMonth == 1; in getFixedDate() 156 return cache.getCachedJan1() + getDayOfYear(jyear, month, dayOfMonth) - 1; in getFixedDate() 168 if (month > 0) { in getFixedDate() 169 days += ((367 * (long) month) - 362) / 12; in getFixedDate() 171 days += CalendarUtils.floorDivide((367 * (long) month) - 362, 12); in getFixedDate() 173 if (month > FEBRUARY) { in getFixedDate() 199 int month = 12 * priorDays + 373; in getCalendarDateFromFixedDate() local 200 if (month > 0) { in getCalendarDateFromFixedDate() 201 month /= 367; in getCalendarDateFromFixedDate() [all …]
|
D | CalendarDate.java | 69 private int month; field in CalendarDate 166 return month; in getMonth() 169 public CalendarDate setMonth(int month) { in setMonth() argument 170 if (this.month != month) { in setMonth() 171 this.month = month; in setMonth() 179 month += n; in addMonth() 305 public CalendarDate setDate(int year, int month, int dayOfMonth) { in setDate() argument 307 setMonth(month); in setDate() 312 public CalendarDate addDate(int year, int month, int dayOfMonth) { in addDate() argument 314 addMonth(month); in addDate() [all …]
|
D | ImmutableGregorianDate.java | 73 public CalendarDate setMonth(int month) { in setMonth() argument 149 public CalendarDate setDate(int year, int month, int dayOfMonth) { in setDate() argument 153 public CalendarDate addDate(int year, int month, int dayOfMonth) { in addDate() argument
|
/libcore/ojluni/src/test/java/time/tck/java/time/chrono/ |
D | CopticDate.java | 108 private final short month; field in CopticDate 127 int month = doy0 / 30 + 1; in ofEpochDay() local 129 return new CopticDate(prolepticYear, month, dom); in ofEpochDay() 132 private static CopticDate resolvePreviousValid(int prolepticYear, int month, int day) { in resolvePreviousValid() argument 133 if (month == 13 && day > 5) { in resolvePreviousValid() 136 return new CopticDate(prolepticYear, month, day); in resolvePreviousValid() 148 CopticDate(int prolepticYear, int month, int dayOfMonth) { in CopticDate() argument 149 CopticChronology.MOY_RANGE.checkValidValue(month, MONTH_OF_YEAR); in CopticDate() 151 if (month == 13) { in CopticDate() 159 this.month = (short) month; in CopticDate() [all …]
|
/libcore/ojluni/src/main/java/java/time/zone/ |
D | ZoneOffsetTransitionRule.java | 111 private final Month month; field in ZoneOffsetTransitionRule 172 Month month, in of() argument 181 Objects.requireNonNull(month, "month"); in of() 193 …return new ZoneOffsetTransitionRule(month, dayOfMonthIndicator, dayOfWeek, time, timeEndOfDay, tim… in of() 214 Month month, in ZoneOffsetTransitionRule() argument 223 this.month = month; in ZoneOffsetTransitionRule() 310 int b = (month.getValue() << 28) + // 4 bits in writeExternal() 342 Month month = Month.of(data >>> 28); in readExternal() local 355 …return ZoneOffsetTransitionRule.of(month, dom, dow, time, timeByte == 24, defn, std, before, after… in readExternal() 370 return month; in getMonth() [all …]
|
/libcore/ojluni/src/main/java/java/sql/ |
D | Date.java | 56 public Date(int year, int month, int day) { in Date() argument 57 super(year, month, day); in Date() 133 int month = Integer.parseInt(mm); in valueOf() local 136 if ((month >= 1 && month <= MAX_MONTH) && (day >= 1 && day <= MAX_DAY)) { in valueOf() 137 d = new Date(year - 1900, month - 1, day); in valueOf() 157 int month = super.getMonth() + 1; in toString() local 165 buf[5] = Character.forDigit(month/10,10); in toString() 166 buf[6] = Character.forDigit(month%10,10); in toString()
|
D | Timestamp.java | 87 public Timestamp(int year, int month, int date, in Timestamp() argument 89 super(year, month, date, hour, minute, second); in Timestamp() 176 int month = 0; in valueOf() local 226 month = Integer.parseInt(mm); in valueOf() 229 if ((month >= 1 && month <= MAX_MONTH) && (day >= 1 && day <= MAX_DAY)) { in valueOf() 263 return new Timestamp(year - 1900, month - 1, day, hour, minute, second, a_nanos); in valueOf() 277 int month = super.getMonth() + 1; in toString() local 301 if (month < 10) { in toString() 302 monthString = "0" + month; in toString() 304 monthString = Integer.toString(month); in toString()
|
/libcore/ojluni/src/main/java/java/util/ |
D | Date.java | 196 public Date(int year, int month, int date) { in Date() argument 197 this(year, month, date, 0, 0, 0); in Date() 219 public Date(int year, int month, int date, int hrs, int min) { in Date() argument 220 this(year, month, date, hrs, min, 0); in Date() 243 public Date(int year, int month, int date, int hrs, int min, int sec) { in Date() argument 246 if (month >= 12) { in Date() 247 y += month / 12; in Date() 248 month %= 12; in Date() 249 } else if (month < 0) { in Date() 250 y += CalendarUtils.floorDivide(month, 12); in Date() [all …]
|
D | GregorianCalendar.java | 640 public GregorianCalendar(int year, int month, int dayOfMonth) { in GregorianCalendar() argument 641 this(year, month, dayOfMonth, 0, 0, 0, 0); in GregorianCalendar() 657 public GregorianCalendar(int year, int month, int dayOfMonth, int hourOfDay, in GregorianCalendar() argument 659 this(year, month, dayOfMonth, hourOfDay, minute, 0, 0); in GregorianCalendar() 677 public GregorianCalendar(int year, int month, int dayOfMonth, int hourOfDay, in GregorianCalendar() argument 679 this(year, month, dayOfMonth, hourOfDay, minute, second, 0); in GregorianCalendar() 698 GregorianCalendar(int year, int month, int dayOfMonth, in GregorianCalendar() argument 703 this.set(MONTH, month); in GregorianCalendar() 957 int month = internalGet(MONTH) + amount; local 961 if (month >= 0) { [all …]
|
/libcore/ojluni/src/main/java/java/time/chrono/ |
D | HijrahChronology.java | 437 public HijrahDate date(Era era, int yearOfEra, int month, int dayOfMonth) { in date() argument 438 return date(prolepticYear(era, yearOfEra), month, dayOfMonth); in date() 452 public HijrahDate date(int prolepticYear, int month, int dayOfMonth) { in date() argument 453 return HijrahDate.of(this, prolepticYear, month, dayOfMonth); in date() 628 void checkValidMonth(int month) { in checkValidMonth() argument 629 if (month < 1 || month > 12) { in checkValidMonth() 630 throw new DateTimeException("Invalid Hijrah month: " + month); in checkValidMonth() 650 int month = epochMonthToMonth(epochMonth); in getHijrahDateInfo() local 656 dateInfo[1] = month + 1; // change to 1-based. in getHijrahDateInfo() 690 int getDayOfYear(int prolepticYear, int month) { in getDayOfYear() argument [all …]
|
D | MinguoChronology.java | 176 public MinguoDate date(Era era, int yearOfEra, int month, int dayOfMonth) { in date() argument 177 return date(prolepticYear(era, yearOfEra), month, dayOfMonth); in date() 191 public MinguoDate date(int prolepticYear, int month, int dayOfMonth) { in date() argument 192 return new MinguoDate(LocalDate.of(prolepticYear + YEARS_DIFFERENCE, month, dayOfMonth)); in date()
|
D | ThaiBuddhistChronology.java | 212 public ThaiBuddhistDate date(Era era, int yearOfEra, int month, int dayOfMonth) { in date() argument 213 return date(prolepticYear(era, yearOfEra), month, dayOfMonth); in date() 227 public ThaiBuddhistDate date(int prolepticYear, int month, int dayOfMonth) { in date() argument 228 … return new ThaiBuddhistDate(LocalDate.of(prolepticYear - YEARS_DIFFERENCE, month, dayOfMonth)); in date()
|
/libcore/ojluni/src/test/java/time/test/java/time/chrono/ |
D | TestJapaneseChronology.java | 154 …public void test_transitions(JapaneseEra era, int yearOfEra, int month, int dayOfMonth, int gregor… in test_transitions() argument 157 JapaneseDate jdate1 = JapaneseDate.of(era, yearOfEra, month, dayOfMonth); in test_transitions() 158 JapaneseDate jdate2 = JapaneseDate.of(gregorianYear, month, dayOfMonth); in test_transitions() 172 …public void test_firstDayOfEra(JapaneseEra era, int yearOfEra, int dayOfYear, int month, int dayOf… in test_firstDayOfEra() argument 174 JapaneseDate date2 = JAPANESE.date(era, yearOfEra, month, dayOfMonth); in test_firstDayOfEra() 179 public void test_invalidDate(JapaneseEra era, int yearOfEra, int month, int dayOfMonth) { in test_invalidDate() argument 180 JapaneseDate jdate = JapaneseDate.of(era, yearOfEra, month, dayOfMonth); in test_invalidDate() 181 …System.out.printf("No DateTimeException with %s %d.%02d.%02d%n", era, yearOfEra, month, dayOfMonth… in test_invalidDate()
|
/libcore/support/src/test/java/tests/support/ |
D | Support_TimeZone.java | 56 int month = cal.get(Calendar.MONTH); in inDaylightTime() local 58 if (month > 4 && month < 10) { in inDaylightTime()
|
/libcore/luni/src/main/java/javax/xml/datatype/ |
D | DatatypeFactory.java | 623 final BigInteger month) { in newDurationYearMonth() argument 628 month, in newDurationYearMonth() 656 final int month) { in newDurationYearMonth() argument 657 return newDuration(isPositive, year, month, in newDurationYearMonth() 790 final int month, in newXMLGregorianCalendar() argument 826 final int month, in newXMLGregorianCalendar() argument 853 month, in newXMLGregorianCalendar() 888 final int month, in newXMLGregorianCalendarDate() argument 894 month, in newXMLGregorianCalendarDate()
|
/libcore/ojluni/src/test/java/time/tck/java/time/format/ |
D | TCKDateTimeFormatters.java | 227 Integer year, Integer month, Integer day, String offsetId, String zoneId, in test_print_isoLocalDate() argument 229 … TemporalAccessor test = buildAccessor(year, month, day, null, null, null, null, offsetId, zoneId); in test_print_isoLocalDate() 244 Integer year, Integer month, Integer day, String offsetId, String zoneId, in test_parse_isoLocalDate() argument 247 Expected expected = createDate(year, month, day); in test_parse_isoLocalDate() 321 Integer year, Integer month, Integer day, String offsetId, String zoneId, in test_print_isoOffsetDate() argument 323 … TemporalAccessor test = buildAccessor(year, month, day, null, null, null, null, offsetId, zoneId); in test_print_isoOffsetDate() 338 Integer year, Integer month, Integer day, String offsetId, String zoneId, in test_parse_isoOffsetDate() argument 341 Expected expected = createDate(year, month, day); in test_parse_isoOffsetDate() 379 Integer year, Integer month, Integer day, String offsetId, String zoneId, in test_print_isoDate() argument 381 … TemporalAccessor test = buildAccessor(year, month, day, null, null, null, null, offsetId, zoneId); in test_print_isoDate() [all …]
|
/libcore/ojluni/src/main/java/sun/security/util/ |
D | DerInputBuffer.java | 313 int year, month, day, hour, minute, second, millis; in getTime() local 334 month = 10 * Character.digit((char)buf[pos++], 10); in getTime() 335 month += Character.digit((char)buf[pos++], 10); in getTime() 394 if (month == 0 || day == 0 in getTime() 395 || month > 12 || day > 31 in getTime() 405 date.setDate(year, month, day); in getTime()
|
/libcore/ojluni/src/test/java/time/tck/java/time/ |
D | TestIsoChronology.java | 179 public void test_badDates(int year, int month, int dom) { in test_badDates() argument 180 IsoChronology.INSTANCE.date(year, month, dom); in test_badDates() 186 int month = 5; in test_date_withEra() local 188 LocalDate test = IsoChronology.INSTANCE.date(IsoEra.BCE, year, month, dayOfMonth); in test_date_withEra() 191 assertEquals(test.get(ChronoField.MONTH_OF_YEAR), month); in test_date_withEra() local
|