/libcore/ojluni/src/main/java/java/time/ |
D | MonthDay.java | 146 private final int day; field in MonthDay 316 this.day = dayOfMonth; in MonthDay() 443 case DAY_OF_MONTH: return day; in getLong() 489 return day; in getDayOfMonth() 504 return (day == 29 && month == 2 && Year.isLeap(year) == false) == false; in isValidYear() 542 int day = Math.min(this.day, month.maxLength()); in with() local 543 return new MonthDay(month.getValue(), day); in with() 560 if (dayOfMonth == this.day) { in withDayOfMonth() 627 … return temporal.with(DAY_OF_MONTH, Math.min(temporal.range(DAY_OF_MONTH).getMaximum(), day)); in adjustInto() 660 return LocalDate.of(year, month, isValidYear(year) ? day : 28); in atYear() [all …]
|
D | LocalDate.java | 180 private final short day; field in LocalDate 471 private static LocalDate resolvePreviousValid(int year, int month, int day) { in resolvePreviousValid() argument 474 day = Math.min(day, IsoChronology.INSTANCE.isLeapYear(year) ? 29 : 28); in resolvePreviousValid() 480 day = Math.min(day, 30); in resolvePreviousValid() 483 return new LocalDate(year, month, day); in resolvePreviousValid() 496 this.day = (short) dayOfMonth; in LocalDate() 691 case ALIGNED_DAY_OF_WEEK_IN_MONTH: return ((day - 1) % 7) + 1; in get0() 693 case DAY_OF_MONTH: return day; in get0() 696 case ALIGNED_WEEK_OF_MONTH: return ((day - 1) / 7) + 1; in get0() 800 return day; in getDayOfMonth() [all …]
|
/libcore/ojluni/src/test/java/time/tck/java/time/temporal/ |
D | TCKWeekFields.java | 152 LocalDate day = LocalDate.of(2000, 1, 10); // Known to be ISO Monday in test_dayOfWeekField() local 157 … assertEquals(day.get(f), (7 + day.getDayOfWeek().getValue() - firstDayOfWeek.getValue()) % 7 + 1); in test_dayOfWeekField() 158 day = day.plusDays(1); in test_dayOfWeekField() 164 LocalDate day = LocalDate.of(2012, 12, 31); // Known to be ISO Monday in test_weekOfMonthField() local 170 int actualDOW = day.get(dowField); in test_weekOfMonthField() 171 int actualWOM = day.get(womField); in test_weekOfMonthField() 175 LocalDate day1 = day.withDayOfMonth(1); in test_weekOfMonthField() 188 assertEquals(result, day, "Incorrect dayOfWeek or weekOfMonth: " in test_weekOfMonthField() 190 week, day.getDayOfWeek(), offset, actualDOW, actualWOM, day, result)); in test_weekOfMonthField() 191 day = day.plusDays(1); in test_weekOfMonthField() [all …]
|
D | TCKTemporalAdjusters.java | 340 for (int day = 1; day <= Month.of(month).length(false); day++) { in test_dayOfWeekInMonth_positive() 341 LocalDate date = date(year, month, day); in test_dayOfWeekInMonth_positive() 368 for (int day = 1; day <= Month.of(month).length(false); day++) { in test_dayOfWeekInMonth_zero() 369 LocalDate date = date(year, month, day); in test_dayOfWeekInMonth_zero() 396 for (int day = 1; day <= Month.of(month).length(false); day++) { in test_dayOfWeekInMonth_negative() 397 LocalDate date = date(year, month, day); in test_dayOfWeekInMonth_negative() 419 for (int day = 1; day <= Month.of(month).length(false); day++) { in test_firstInMonth() 420 LocalDate date = date(year, month, day); in test_firstInMonth() 422 assertEquals(test, expected, "day-of-month=" + day); in test_firstInMonth() 441 for (int day = 1; day <= Month.of(month).length(false); day++) { in test_lastInMonth() [all …]
|
/libcore/ojluni/src/test/java/time/tck/java/time/chrono/ |
D | CopticDate.java | 113 private final short day; field in CopticDate 133 private static CopticDate resolvePreviousValid(int prolepticYear, int month, int day) { in resolvePreviousValid() argument 134 if (month == 13 && day > 5) { in resolvePreviousValid() 135 day = CopticChronology.INSTANCE.isLeapYear(prolepticYear) ? 6 : 5; in resolvePreviousValid() 137 return new CopticDate(prolepticYear, month, day); in resolvePreviousValid() 161 this.day = (short) dayOfMonth; in CopticDate() 216 case ALIGNED_DAY_OF_WEEK_IN_MONTH: return ((day - 1) % 7) + 1; in getLong() 218 case DAY_OF_MONTH: return day; in getLong() 219 case DAY_OF_YEAR: return (month - 1) * 30 + day; in getLong() 221 case ALIGNED_WEEK_OF_MONTH: return ((day - 1) / 7) + 1; in getLong() [all …]
|
/libcore/ojluni/src/main/java/java/sql/ |
D | Date.java | 57 public Date(int year, int month, int day) { in Date() argument 58 super(year, month, day); in Date() 135 int day = Integer.parseInt(dd); in valueOf() local 137 if ((month >= 1 && month <= MAX_MONTH) && (day >= 1 && day <= MAX_DAY)) { in valueOf() 138 d = new Date(year - 1900, month - 1, day); in valueOf() 159 int day = super.getDate(); in toString() local 168 buf[8] = Character.forDigit(day/10,10); in toString() 169 buf[9] = Character.forDigit(day%10,10); in toString()
|
D | Timestamp.java | 177 int day = 0; in valueOf() local 227 day = Integer.parseInt(dd); 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() 278 int day = super.getDate(); in toString() local 306 if (day < 10) { in toString() 307 dayString = "0" + day; in toString() 309 dayString = Integer.toString(day); in toString()
|
/libcore/luni/src/test/java/libcore/javax/xml/datatype/ |
D | XMLGregorianCalendarTest.java | 75 private int day; field in XMLGregorianCalendarTest.XMLGregorianCalendarImpl 85 year = month = day = hour = minute = second = millisecond = timezoneOffset = 0; in clear() 91 year = month = day = hour = minute = second = millisecond = timezoneOffset = 0; in reset() 111 public void setDay(int day) { in setDay() argument 112 this.day = day; in setDay() 167 return day; in getDay() 199 if (day != rhs.getDay()) return day - rhs.getDay(); in compare()
|
/libcore/luni/src/main/java/javax/xml/datatype/ |
D | DatatypeFactory.java | 468 final BigInteger day, in newDurationDayTime() argument 477 day, in newDurationDayTime() 510 final int day, in newDurationDayTime() argument 516 day, hour, minute, second); in newDurationDayTime() 791 final int day, in newXMLGregorianCalendar() argument 827 final int day, in newXMLGregorianCalendar() argument 854 day, in newXMLGregorianCalendar() 889 final int day, in newXMLGregorianCalendarDate() argument 895 day, in newXMLGregorianCalendarDate()
|
D | XMLGregorianCalendar.java | 295 public abstract void setDay(int day); in setDay() argument
|
/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 …]
|
D | TCKResolverStyle.java | 110 …resolverStyle(String str, ResolverStyle style, Class<?> expectedEx, int year, int month, int day) { in test_resolverStyle() argument 129 assertEquals(accessor.get(ChronoField.DAY_OF_MONTH), day); in test_resolverStyle() local
|
/libcore/ojluni/src/main/java/java/util/zip/ |
D | ZipUtils.java | 92 int day = (int) ((dtime >> 16) & 0x1f); in dosToJavaTime() local 97 if (month > 0 && month < 13 && day > 0 && hour < 24 && minute < 60 && second < 60) { in dosToJavaTime() 99 LocalDateTime ldt = LocalDateTime.of(year, month, day, hour, minute, second); in dosToJavaTime() 106 return overflowDosToJavaTime(year, month, day, hour, minute, second); in dosToJavaTime() 113 private static long overflowDosToJavaTime(int year, int month, int day, in overflowDosToJavaTime() argument 115 return new Date(year - 1900, month - 1, day, hour, minute, second).getTime(); in overflowDosToJavaTime()
|
/libcore/ojluni/src/main/java/sun/security/util/ |
D | DerInputBuffer.java | 313 int year, month, day, hour, minute, second, millis; in getTime() local 337 day = 10 * Character.digit((char)buf[pos++], 10); in getTime() 338 day += 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/test/java/time/chrono/ |
D | TestExampleCode.java | 90 int day = now1.get(ChronoField.DAY_OF_MONTH); in test_chronoPackageExample() local 95 dow, day, month, year); in test_chronoPackageExample() 150 int day = now1.get(ChronoField.DAY_OF_MONTH); in test_calendarPackageExample() local 155 dow, day, month, year); in test_calendarPackageExample()
|
D | TestUmmAlQuraChronology.java | 136 ValueRange day = chrono.range(DAY_OF_MONTH); in Test_UmmAlQuraChronoRange() local 137 assertEquals(day.getMinimum(), 1, "Minimum day"); in Test_UmmAlQuraChronoRange() 138 assertEquals(day.getLargestMinimum(), 1, "Largest minimum day"); in Test_UmmAlQuraChronoRange() 139 assertEquals(day.getMaximum(), 30, "Largest day"); in Test_UmmAlQuraChronoRange() 140 assertEquals(day.getSmallestMaximum(), 29, "Smallest Maximum day"); in Test_UmmAlQuraChronoRange() 442 public void test_ofPattern(int year, int month, int day, String expected) { in test_ofPattern() argument 444 assertEquals(test.format(HijrahDate.of(year, month, day)), expected); in test_ofPattern() 459 public void test_formatterOfLocalizedDate(int year, int month, int day, String expected) { in test_formatterOfLocalizedDate() argument 460 HijrahDate hd = HijrahChronology.INSTANCE.date(year, month, day); in test_formatterOfLocalizedDate()
|
/libcore/luni/src/test/java/libcore/java/util/ |
D | CalendarTest.java | 150 private void testSetSelfConsistent(TimeZone timeZone, int year, int month, int day) { in testSetSelfConsistent() argument 155 calendar.set(year, month, day, hour, minute); in testSetSelfConsistent() 158 assertEquals(day, calendar.get(Calendar.DAY_OF_MONTH)); in testSetSelfConsistent() 214 int year, int month, int day, int hour, int minute) { in assertCalendarEquals() argument 217 assertEquals("day", day, calendar.get(Calendar.DATE)); in assertCalendarEquals()
|
/libcore/ojluni/src/main/java/java/time/chrono/ |
D | HijrahDate.java | 414 private HijrahDate resolvePreviousValid(int prolepticYear, int month, int day) { in resolvePreviousValid() argument 416 if (day > monthDays) { in resolvePreviousValid() 417 day = monthDays; in resolvePreviousValid() 419 return HijrahDate.of(chrono, prolepticYear, month, day); in resolvePreviousValid()
|
/libcore/luni/src/main/java/libcore/util/ |
D | ZoneInfo.java | 199 public int getOffset(int era, int year, int month, int day, int dayOfWeek, int millis) { in getOffset() argument 218 calc += (day - 1) * MILLISECONDS_PER_DAY; in getOffset()
|
/libcore/ojluni/src/test/java/time/test/java/time/format/ |
D | TestReducedPrinter.java | 269 public void test_printAdjacent(String pattern, String text, int year, int month, int day) { in test_printAdjacent() argument 274 LocalDate ld = LocalDate.of(year, month, day); in test_printAdjacent()
|
/libcore/ojluni/src/main/java/sun/util/calendar/ |
D | LocalGregorianCalendar.java | 312 int day = ldate.getDayOfMonth(); in normalize() local 314 if (day > sinceDay) { in normalize() 317 if (day == sinceDay) { in normalize()
|
/libcore/ojluni/src/main/java/java/util/ |
D | SimpleTimeZone.java | 604 public int getOffset(int era, int year, int month, int day, int dayOfWeek, in getOffset() argument 637 cdate.setDate(y, m, day); in getOffset() 650 cdate.setNormalizedDate(y, m, day); in getOffset() 656 || (cdate.getDayOfMonth() != day) in getOffset()
|
/libcore/ojluni/src/main/java/java/time/temporal/ |
D | WeekFields.java | 894 private int startOfWeekOffset(int day, int dow) { in startOfWeekOffset() argument 896 int weekStart = Math.floorMod(day - dow, 7); in startOfWeekOffset() 913 private int computeWeek(int offset, int day) { in computeWeek() argument 914 return ((7 + offset + (day - 1)) / 7); in computeWeek()
|
/libcore/ojluni/src/test/java/time/test/java/time/ |
D | TestZoneId.java | 650 private Instant createInstant(int year, int month, int day, ZoneOffset offset) { in createInstant() argument 651 return LocalDateTime.of(year, month, day, 0, 0).toInstant(offset); in createInstant() 654 …private Instant createInstant(int year, int month, int day, int hour, int min, int sec, int nano, … in createInstant() argument 655 return LocalDateTime.of(year, month, day, hour, min, sec, nano).toInstant(offset); in createInstant() 658 …private ZonedDateTime createZDT(int year, int month, int day, int hour, int min, int sec, int nano… in createZDT() argument 659 return LocalDateTime.of(year, month, day, hour, min, sec, nano).atZone(zone); in createZDT() 662 private LocalDateTime createLDT(int year, int month, int day) { in createLDT() argument 663 return LocalDateTime.of(year, month, day, 0, 0); in createLDT()
|
/libcore/ojluni/src/test/java/time/tck/java/time/zone/ |
D | TCKZoneRules.java | 1135 private Instant createInstant(int year, int month, int day, ZoneOffset offset) { in createInstant() argument 1136 return LocalDateTime.of(year, month, day, 0, 0).toInstant(offset); in createInstant() 1139 …private Instant createInstant(int year, int month, int day, int hour, int min, ZoneOffset offset) { in createInstant() argument 1140 return LocalDateTime.of(year, month, day, hour, min).toInstant(offset); in createInstant() 1143 …private Instant createInstant(int year, int month, int day, int hour, int min, int sec, int nano, … in createInstant() argument 1144 return LocalDateTime.of(year, month, day, hour, min, sec, nano).toInstant(offset); in createInstant() 1147 private ZonedDateTime createZDT(int year, int month, int day, ZoneId zone) { in createZDT() argument 1148 return LocalDateTime.of(year, month, day, 0, 0).atZone(zone); in createZDT() 1151 private LocalDateTime createLDT(int year, int month, int day) { in createLDT() argument 1152 return LocalDateTime.of(year, month, day, 0, 0); in createLDT()
|