/libcore/ojluni/src/main/java/java/time/temporal/ |
D | ChronoField.java | 70 import static java.time.temporal.ChronoUnit.DAYS; 138 NANO_OF_DAY("NanoOfDay", NANOS, DAYS, ValueRange.of(0, 86400L * 1000_000_000L - 1)), 177 MICRO_OF_DAY("MicroOfDay", MICROS, DAYS, ValueRange.of(0, 86400L * 1000_000L - 1)), 216 MILLI_OF_DAY("MilliOfDay", MILLIS, DAYS, ValueRange.of(0, 86400L * 1000L - 1)), 238 SECOND_OF_DAY("SecondOfDay", SECONDS, DAYS, ValueRange.of(0, 86400L - 1)), 259 MINUTE_OF_DAY("MinuteOfDay", MINUTES, DAYS, ValueRange.of(0, (24 * 60) - 1)), 302 HOUR_OF_DAY("HourOfDay", HOURS, DAYS, ValueRange.of(0, 23), "hour"), 316 CLOCK_HOUR_OF_DAY("ClockHourOfDay", HOURS, DAYS, ValueRange.of(1, 24)), 329 AMPM_OF_DAY("AmPmOfDay", HALF_DAYS, DAYS, ValueRange.of(0, 1), "dayperiod"), 345 DAY_OF_WEEK("DayOfWeek", DAYS, WEEKS, ValueRange.of(1, 7), "weekday"), [all …]
|
D | TemporalAdjusters.java | 67 import static java.time.temporal.ChronoUnit.DAYS; 355 return temp.plus(dowDiff, DAYS); in dayOfWeekInMonth() 364 return temp.plus(daysDiff, DAYS); in dayOfWeekInMonth() 391 return temporal.plus(daysDiff >= 0 ? 7 - daysDiff : -daysDiff, DAYS); 420 return temporal.plus(daysDiff >= 0 ? 7 - daysDiff : -daysDiff, DAYS); 445 return temporal.minus(daysDiff >= 0 ? 7 - daysDiff : -daysDiff, DAYS); 474 return temporal.minus(daysDiff >= 0 ? 7 - daysDiff : -daysDiff, DAYS);
|
D | ChronoUnit.java | 125 DAYS("Days", Duration.ofSeconds(86400)), enumConstant 227 return this.compareTo(DAYS) >= 0; in isDurationEstimated() 241 return this.compareTo(DAYS) >= 0 && this != FOREVER; in isDateBased() 254 return this.compareTo(DAYS) < 0; in isTimeBased()
|
D | JulianFields.java | 65 import static java.time.temporal.ChronoUnit.DAYS; 215 JULIAN_DAY("JulianDay", DAYS, FOREVER, JULIAN_DAY_OFFSET), 216 MODIFIED_JULIAN_DAY("ModifiedJulianDay", DAYS, FOREVER, 40587L), 217 RATA_DIE("RataDie", DAYS, FOREVER, 719163L);
|
D | WeekFields.java | 73 import static java.time.temporal.ChronoUnit.DAYS; 676 return new ComputedDayOfField("DayOfWeek", weekDef, DAYS, WEEKS, DAY_OF_WEEK_RANGE); in ofDayOfWeekField() 736 return date.plus(days, DAYS); in ofWeekBasedYear() 846 date = date.minus(doy, DAYS); // Back down into previous year in localizedWeekOfWeekBasedYear() 964 date = date.plus(Math.addExact(Math.multiplyExact(weeks, 7), days), DAYS); in resolveWoM() 971 date = date.plus(weeks * 7 + days, DAYS); in resolveWoM() 989 date = date.plus(Math.addExact(Math.multiplyExact(weeks, 7), days), DAYS); in resolveWoY() 994 date = date.plus(weeks * 7 + days, DAYS); in resolveWoY() 1137 date = date.minus(doy + 7, DAYS); // Back down into previous year in rangeWeekOfWeekBasedYear() 1148 date = date.plus(yearLen - doy + 1 + 7, ChronoUnit.DAYS); in rangeWeekOfWeekBasedYear()
|
/libcore/ojluni/src/test/java/nio/file/attribute/ |
D | FileTimeTest.java | 50 long tomorrowInDays = TimeUnit.DAYS.convert(now, MILLISECONDS) + 1; in main() 51 long yesterdayInDays = TimeUnit.DAYS.convert(now, MILLISECONDS) - 1; in main() 72 cmp(tomorrowInDays, DAYS, now, MILLISECONDS, 1); in main() 73 cmp(now, MILLISECONDS, tomorrowInDays, DAYS, -1); in main() 74 cmp(yesterdayInDays, DAYS, now, MILLISECONDS, -1); in main() 75 cmp(now, MILLISECONDS, yesterdayInDays, DAYS, 1); in main() 76 cmp(yesterdayInDays, DAYS, now, MILLISECONDS, -1); in main() 78 cmp(Long.MAX_VALUE, DAYS, Long.MAX_VALUE, NANOSECONDS, 1); in main() 79 cmp(Long.MAX_VALUE, DAYS, Long.MIN_VALUE, NANOSECONDS, 1); in main() 80 cmp(Long.MIN_VALUE, DAYS, Long.MIN_VALUE, NANOSECONDS, -1); in main() [all …]
|
/libcore/jsr166-tests/src/test/java/jsr166/ |
D | TimeUnitTest.java | 11 import static java.util.concurrent.TimeUnit.DAYS; 44 SECONDS.convert(t, DAYS)); in testConvert() 59 MILLISECONDS.convert(t, DAYS)); in testConvert() 74 MICROSECONDS.convert(t, DAYS)); in testConvert() 89 NANOSECONDS.convert(t, DAYS)); in testConvert() 112 DAYS.toNanos(t)); in testToNanos() 135 DAYS.toMicros(t)); in testToMicros() 158 DAYS.toMillis(t)); in testToMillis() 181 DAYS.toSeconds(t)); in testToSeconds() 204 DAYS.toMinutes(t)); in testToMinutes() [all …]
|
/libcore/ojluni/src/test/java/time/tck/java/time/temporal/ |
D | TCKChronoField.java | 87 import static java.time.temporal.ChronoUnit.DAYS; 127 {DAY_OF_MONTH, DAYS, MONTHS}, in data_fieldUnit() 128 {DAY_OF_WEEK, DAYS, WEEKS}, in data_fieldUnit() 129 {DAY_OF_YEAR, DAYS, YEARS}, in data_fieldUnit() 130 {HOUR_OF_DAY, HOURS, DAYS}, in data_fieldUnit() 131 {MINUTE_OF_DAY, MINUTES, DAYS}, in data_fieldUnit() 133 {SECOND_OF_DAY, SECONDS, DAYS}, in data_fieldUnit() 135 {MILLI_OF_DAY, MILLIS, DAYS}, in data_fieldUnit() 138 {MICRO_OF_DAY, MICROS, DAYS}, in data_fieldUnit() 140 {NANO_OF_DAY, NANOS, DAYS}, in data_fieldUnit()
|
D | TCKChronoUnit.java | 60 import static java.time.temporal.ChronoUnit.DAYS; 109 {DAYS, true, false, true}, in data_chronoUnit() 140 {DAYS, LocalDate.of(2000, 1, 10), true, 1, LocalDate.of(2000, 1, 11)}, in data_unitAndTemporal() 155 {DAYS, LocalTime.of(1, 2, 3, 400), false, 1, null}, in data_unitAndTemporal()
|
/libcore/ojluni/src/test/java/time/test/java/time/chrono/ |
D | TestChronoLocalDate.java | 93 dates.add(date.minus(1, ChronoUnit.DAYS)); in test_date_comparator_checkGenerics_ISO() 95 dates.add(date.plus(1, ChronoUnit.DAYS)); in test_date_comparator_checkGenerics_ISO() 117 dates.add(date.minus(1, ChronoUnit.DAYS)); 119 dates.add(date.plus(1, ChronoUnit.DAYS)); 174 return (D) date.plus(1, ChronoUnit.DAYS);
|
D | TestExampleCode.java | 110 .minus(1, ChronoUnit.DAYS); in test_chronoPackageExample() 163 .minus(1, ChronoUnit.DAYS); in test_calendarPackageExample() 204 return (D) date.plus(1, ChronoUnit.DAYS); in next() 216 return (ChronoLocalDateTime<D>) date.plus(1, ChronoUnit.DAYS).atTime(LocalTime.of(12, 0)); in tomorrowNoon()
|
D | TestIsoChronoImpl.java | 109 isoDate = isoDate.plus(1, ChronoUnit.DAYS); in test_IsoChrono_vsCalendar() 161 isoDate = isoDate.plus(1, ChronoUnit.DAYS); in test_DayOfWeek_IsoChronology_vsCalendar()
|
/libcore/ojluni/src/test/java/time/test/java/time/temporal/ |
D | TestChronoUnit.java | 66 import static java.time.temporal.ChronoUnit.DAYS; 292 assertEquals(DAYS.between(start, end), expected); in test_daysBetween() 297 assertEquals(DAYS.between(end, start), -expected); in test_daysBetweenReversed() 302 assertEquals(DAYS.between(start.atTime(12, 30), end.atTime(12, 30)), expected); in test_daysBetween_LocalDateTimeSameTime() 308 assertEquals(DAYS.between(start.atTime(12, 30), end.atTime(12, 31)), expected); in test_daysBetween_LocalDateTimeLaterTime() 310 assertEquals(DAYS.between(start.atTime(12, 30), end.atTime(12, 29)), expected); in test_daysBetween_LocalDateTimeLaterTime() 316 …assertEquals(DAYS.between(start.atStartOfDay(ZoneOffset.ofHours(2)), end.atStartOfDay(ZoneOffset.o… in test_daysBetween_ZonedDateSameOffset() 323 …assertEquals(DAYS.between(start.atStartOfDay(ZoneOffset.ofHours(2)), end.atStartOfDay(ZoneOffset.o… in test_daysBetween_ZonedDateLaterOffset() 325 …assertEquals(DAYS.between(start.atStartOfDay(ZoneOffset.ofHours(1)), end.atStartOfDay(ZoneOffset.o… in test_daysBetween_ZonedDateLaterOffset()
|
/libcore/ojluni/src/main/java/java/time/chrono/ |
D | ChronoPeriodImpl.java | 60 import static java.time.temporal.ChronoUnit.DAYS; 109 Collections.unmodifiableList(Arrays.<TemporalUnit>asList(YEARS, MONTHS, DAYS)); 146 } else if (unit == ChronoUnit.DAYS) { in get() 276 temporal = temporal.plus(days, DAYS); in addTo() 302 temporal = temporal.minus(days, DAYS); in subtractFrom()
|
D | AbstractChronology.java | 77 import static java.time.temporal.ChronoUnit.DAYS; 556 return date(y, 1, 1).plus(months, MONTHS).plus(days, DAYS); in resolveYMD() 575 return dateYearDay(y, 1).plus(days, DAYS); in resolveYD() 587 return date(y, 1, 1).plus(months, MONTHS).plus(weeks, WEEKS).plus(days, DAYS); in resolveYMAA() 592 ChronoLocalDate date = date(y, moy, 1).plus((aw - 1) * 7 + (ad - 1), DAYS); in resolveYMAA() 610 …ChronoLocalDate date = date(y, moy, 1).plus((aw - 1) * 7, DAYS).with(nextOrSame(DayOfWeek.of(dow))… in resolveYMAD() 622 return dateYearDay(y, 1).plus(weeks, WEEKS).plus(days, DAYS); in resolveYAA() 626 ChronoLocalDate date = dateYearDay(y, 1).plus((aw - 1) * 7 + (ad - 1), DAYS); in resolveYAA() 642 …ChronoLocalDate date = dateYearDay(y, 1).plus((aw - 1) * 7, DAYS).with(nextOrSame(DayOfWeek.of(dow… in resolveYAD()
|
/libcore/ojluni/src/test/java/time/tck/java/time/chrono/ |
D | TCKChronoPeriod.java | 59 import static java.time.temporal.ChronoUnit.DAYS; 123 assertEquals(period.get(DAYS), 3); in test_get() 138 assertEquals(period.getUnits().get(2), DAYS); in test_getUnits() 205 assertEquals(result, date.plus(14, MONTHS).plus(3, DAYS)); in test_addTo() 223 assertEquals(result, date.minus(14, MONTHS).minus(3, DAYS)); in test_subtractFrom()
|
/libcore/ojluni/src/test/java/time/tck/java/time/temporal/serial/ |
D | TCKChronoUnitSerialization.java | 60 import static java.time.temporal.ChronoUnit.DAYS; 104 {DAYS}, in data_chronoUnit()
|
/libcore/ojluni/src/main/java/java/time/ |
D | Period.java | 64 import static java.time.temporal.ChronoUnit.DAYS; 150 Collections.unmodifiableList(Arrays.<TemporalUnit>asList(YEARS, MONTHS, DAYS)); 273 } else if (unit == ChronoUnit.DAYS) { in from() 431 } else if (unit == ChronoUnit.DAYS) { in get() 900 temporal = temporal.plus(days, DAYS); in addTo() 953 temporal = temporal.minus(days, DAYS); in subtractFrom()
|
D | DayOfWeek.java | 65 import static java.time.temporal.ChronoUnit.DAYS; 408 return (R) DAYS; in query()
|
/libcore/ojluni/src/test/java/time/test/java/time/ |
D | MockSimplePeriod.java | 62 import static java.time.temporal.ChronoUnit.DAYS; 82 public static final MockSimplePeriod ZERO_DAYS = new MockSimplePeriod(0, DAYS);
|
/libcore/ojluni/src/test/java/time/tck/java/time/ |
D | MockSimplePeriod.java | 62 import static java.time.temporal.ChronoUnit.DAYS; 82 public static final MockSimplePeriod ZERO_DAYS = new MockSimplePeriod(0, DAYS);
|
D | TCKPeriod.java | 62 import static java.time.temporal.ChronoUnit.DAYS; 179 list.add(DAYS); in factory_from_TemporalAmount_YearsDays() 222 if (unit == DAYS) { in factory_from_TemporalAmount_DaysHours() 231 list.add(DAYS); in factory_from_TemporalAmount_DaysHours() 648 if (unit == DAYS) { in test_plus_TemporalAmount_DaysHours() 657 list.add(DAYS); in test_plus_TemporalAmount_DaysHours() 793 if (unit == DAYS) { in test_minus_TemporalAmount_DaysHours() 802 list.add(DAYS); in test_minus_TemporalAmount_DaysHours() 1142 assertEquals(units.get(2), ChronoUnit.DAYS, "Period.getUnits contains ChronoUnit.DAYS"); in test_Period_getUnits() 1149 {2, ChronoUnit.DAYS}, in data_goodTemporalUnit()
|
D | TCKLocalDateTime.java | 91 import static java.time.temporal.ChronoUnit.DAYS; 967 assertEquals(TEST_2007_07_15_12_30_40_987654321.isSupported(ChronoUnit.DAYS), true); 1368 …assertEquals(TEST_2007_07_15_12_30_40_987654321.truncatedTo(DAYS), TEST_2007_07_15_12_30_40_987654… 1388 MockSimplePeriod period = MockSimplePeriod.of(-25, DAYS); 1421 LocalDateTime t = TEST_2007_07_15_12_30_40_987654321.plus(-25, ChronoUnit.DAYS); 2077 MockSimplePeriod period = MockSimplePeriod.of(-25, DAYS); 2110 LocalDateTime t = TEST_2007_07_15_12_30_40_987654321.minus(-25, ChronoUnit.DAYS); 2764 {dtNoon(2000, 1, 1), dtNoon(2000, 1, 1), DAYS, 0}, 2772 {dtNoon(2000, 1, 15), dtNoon(2000, 2, 14), DAYS, 30}, 2773 {dtNoon(2000, 1, 15), dtNoon(2000, 2, 15), DAYS, 31}, [all …]
|
/libcore/luni/src/main/java/javax/xml/datatype/ |
D | Duration.java | 160 boolean daySet = isSet(DatatypeConstants.DAYS); in getXMLSchemaType() 256 return getFieldValueAsInt(DatatypeConstants.DAYS); in getDays() 902 BigInteger days = (BigInteger) getField(DatatypeConstants.DAYS); in toString()
|
/libcore/ojluni/src/main/java/java/nio/file/attribute/ |
D | FileTime.java | 235 case DAYS: in toInstant() 318 return unit.toNanos(value - unit.convert(days, TimeUnit.DAYS)); in toExcessNanos() 321 - TimeUnit.DAYS.toSeconds(days)); in toExcessNanos()
|