/libcore/ojluni/src/main/java/java/time/ |
D | Duration.java | 705 case NANOS: return plusNanos(amountToAdd); in plus() 706 …e MICROS: return plusSeconds((amountToAdd / (1000_000L * 1000)) * 1000).plusNanos((amountToAdd % (… in plus() 713 return plusSeconds(duration.getSeconds()).plusNanos(duration.getNano()); in plus() 794 public Duration plusNanos(long nanosToAdd) { in plusNanos() method in Duration 940 …return (nanosToSubtract == Long.MIN_VALUE ? plusNanos(Long.MAX_VALUE).plusNanos(1) : plusNanos(-na… in minusNanos() 1361 return plusNanos(result - nod); in truncatedTo()
|
D | Instant.java | 755 return plusNanos(result - nod); in truncatedTo() 846 case NANOS: return plusNanos(amountToAdd); in plus() 899 public Instant plusNanos(long nanosToAdd) { in plusNanos() method in Instant 1022 return plusNanos(Long.MAX_VALUE).plusNanos(1); in minusNanos() 1024 return plusNanos(-nanosToSubtract); in minusNanos()
|
D | LocalTime.java | 1064 case NANOS: return plusNanos(amountToAdd); in plus() 1065 case MICROS: return plusNanos((amountToAdd % MICROS_PER_DAY) * 1000); in plus() 1066 case MILLIS: return plusNanos((amountToAdd % MILLIS_PER_DAY) * 1000_000); in plus() 1160 public LocalTime plusNanos(long nanosToAdd) { in plusNanos() method in LocalTime 1284 return plusNanos(-(nanosToSubtract % NANOS_PER_DAY)); in minusNanos()
|
D | OffsetDateTime.java | 1324 public OffsetDateTime plusNanos(long nanos) { in plusNanos() method in OffsetDateTime 1325 return with(dateTime.plusNanos(nanos), offset); in plusNanos() 1514 … return (nanos == Long.MIN_VALUE ? plusNanos(Long.MAX_VALUE).plusNanos(1) : plusNanos(-nanos)); in minusNanos()
|
D | ZonedDateTime.java | 1775 public ZonedDateTime plusNanos(long nanos) { in plusNanos() method in ZonedDateTime 1776 return resolveInstant(dateTime.plusNanos(nanos)); in plusNanos() 2021 … return (nanos == Long.MIN_VALUE ? plusNanos(Long.MAX_VALUE).plusNanos(1) : plusNanos(-nanos)); in minusNanos()
|
D | LocalDateTime.java | 1174 case NANOS: return plusNanos(amountToAdd); in plus() 1175 …case MICROS: return plusDays(amountToAdd / MICROS_PER_DAY).plusNanos((amountToAdd % MICROS_PER_DAY… in plus() 1176 …case MILLIS: return plusDays(amountToAdd / MILLIS_PER_DAY).plusNanos((amountToAdd % MILLIS_PER_DAY… in plus() 1327 public LocalDateTime plusNanos(long nanos) { in plusNanos() method in LocalDateTime
|
D | OffsetTime.java | 937 public OffsetTime plusNanos(long nanos) { in plusNanos() method in OffsetTime 938 return with(time.plusNanos(nanos), offset); in plusNanos()
|
/libcore/ojluni/src/main/java/java/time/chrono/ |
D | ChronoLocalDateTimeImpl.java | 303 case NANOS: return plusNanos(amountToAdd); in plus() 304 …case MICROS: return plusDays(amountToAdd / MICROS_PER_DAY).plusNanos((amountToAdd % MICROS_PER_DAY… in plus() 305 …case MILLIS: return plusDays(amountToAdd / MILLIS_PER_DAY).plusNanos((amountToAdd % MILLIS_PER_DAY… in plus() 332 private ChronoLocalDateTimeImpl<D> plusNanos(long nanos) { in plusNanos() method in ChronoLocalDateTimeImpl
|
/libcore/ojluni/src/test/java/time/test/java/time/ |
D | TestDuration.java | 121 assertSame(t.plusNanos(0), t); in plusNanos_zeroReturnsThis() 127 assertSame(t.plusNanos(998000000), Duration.ZERO); in plusNanos_zeroSingleton()
|
D | TestLocalDateTime.java | 332 LocalDateTime t = TEST_2007_07_15_12_30_40_987654321.plusNanos(0); in test_plusNanos_noChange() 338 LocalDateTime t = TEST_2007_07_15_12_30_40_987654321.plusNanos(24 * 60 * 60 * 1000000000L); in test_plusNanos_noChange_oneDay_same() 344 …Time t = TEST_2007_07_15_12_30_40_987654321.with(LocalTime.of(23, 59, 59, 999999999)).plusNanos(1); in test_plusNanos_toMidnight() 350 …Time t = TEST_2007_07_15_12_30_40_987654321.with(LocalTime.of(11, 59, 59, 999999999)).plusNanos(1); in test_plusNanos_toMidday()
|
D | TestOffsetDateTime.java | 262 OffsetDateTime test = base.plusNanos(0); in test_plusNanos_zero()
|
/libcore/luni/src/test/java/libcore/java/time/ |
D | DurationTest.java | 75 { Instant.EPOCH, Duration.between(Instant.EPOCH, Instant.MAX).plusNanos(1) }, in test_addTo_exceeds() 102 { Instant.EPOCH, Duration.between(Instant.MIN, Instant.EPOCH).plusNanos(1) }, in test_subtractFrom_exceeds()
|
/libcore/ojluni/annotations/hiddenapi/java/time/ |
D | Duration.java | 209 public java.time.Duration plusNanos(long nanosToAdd) { in plusNanos() method in Duration
|
D | OffsetDateTime.java | 309 public java.time.OffsetDateTime plusNanos(long nanos) { in plusNanos() method in OffsetDateTime
|
/libcore/ojluni/src/test/java/time/tck/java/time/ |
D | TCKLocalTime.java | 1740 t = t.plusNanos(500000000); in test_plusNanos_halfABillion() 1811 LocalTime t = base.plusNanos(nanoseconds); 1821 LocalTime t = TEST_12_30_40_987654321.plusNanos(0); 1827 LocalTime t = TEST_12_30_40_987654321.plusNanos(24 * 60 * 60 * 1000000000L); 1833 LocalTime t = LocalTime.of(23, 59, 59, 999999999).plusNanos(1); 1839 LocalTime t = LocalTime.of(11, 59, 59, 999999999).plusNanos(1); 2475 t = t.plusNanos(1); 2489 t = t.plusNanos(1);
|
D | TCKInstant.java | 208 Instant expected = Instant.ofEpochSecond(i).plusNanos(123456789L); 218 Instant expected = Instant.ofEpochSecond(i).plusNanos(123456789L); 1201 t = t.plusNanos(amount); 1209 t.plusNanos(1); 1215 t.plusNanos(-1);
|
D | TCKOffsetDateTime.java | 257 Instant instant = Instant.ofEpochSecond(i).plusNanos(123456789L); 274 Instant instant = Instant.ofEpochSecond(i).plusNanos(123456789L); 290 LocalTime expected = LocalTime.MIDNIGHT.plusNanos(123456789L); 292 Instant instant = Instant.ofEpochSecond(i).plusNanos(123456789L); 1013 OffsetDateTime test = base.plusNanos(1);
|
D | TCKZonedDateTime.java | 271 Instant instant = Instant.ofEpochSecond(i).plusNanos(123456789L); 290 Instant instant = Instant.ofEpochSecond(i).plusNanos(123456789L); 300 LocalTime expected = LocalTime.MIDNIGHT.plusNanos(123456789L); 302 Instant instant = Instant.ofEpochSecond(i).plusNanos(123456789L); 1810 assertEquals(base.plusNanos(amount * 3600_000_000_000L), expected); 1817 ZonedDateTime test = base.plusNanos(1); 1818 assertEquals(test, ZonedDateTime.of(ldt.plusNanos(1), ZONE_0100));
|
D | TCKLocalDateTime.java | 303 Instant instant = Instant.ofEpochSecond(i).plusNanos(123456789L); 319 Instant instant = Instant.ofEpochSecond(i).plusNanos(123456789L); 334 LocalTime expected = LocalTime.MIDNIGHT.plusNanos(123456789L); 336 Instant instant = Instant.ofEpochSecond(i).plusNanos(123456789L); 1968 t = t.plusNanos(500000000); 2044 LocalDateTime t = base.plusNanos(nanoseconds); 2055 LocalDateTime t = TEST_2007_07_15_12_30_40_987654321.plusNanos(24 * 60 * 60 * 1000000000L);
|
D | TCKDuration.java | 1531 t = t.plusNanos(amount); in plusNanos_long() 1539 t.plusNanos(1); in plusNanos_long_overflowTooBig() 1545 t.plusNanos(-1); in plusNanos_long_overflowTooSmall() 2646 Duration test = Duration.ofSeconds(0, Long.MAX_VALUE).plusNanos(1); in test_toNanos_tooBig()
|
D | TCKOffsetTime.java | 959 OffsetTime test = base.plusNanos(1); 966 OffsetTime test = base.plusNanos(0);
|
/libcore/ojluni/src/test/java/time/tck/java/time/zone/ |
D | TCKZoneRules.java | 473 assertEquals(test.previousTransition(prev.getInstant().plusNanos(1)), prev); in test_London_previousTransition_historic() 485 assertEquals(test.previousTransition(last.getInstant().plusNanos(1)), last); in test_London_previousTransition_rulesBased() 500 assertEquals(test.previousTransition(b.getInstant().plusNanos(1)), b); in test_London_previousTransition_rulesBased() 504 assertEquals(test.previousTransition(a.getInstant().plusNanos(1)), a); in test_London_previousTransition_rulesBased()
|
/libcore/api/ |
D | current.txt | 11456 method public java.time.Duration plusNanos(long); 11505 method public java.time.Instant plusNanos(long); 11659 method public java.time.LocalDateTime plusNanos(long); 11722 method public java.time.LocalTime plusNanos(long); 11851 method public java.time.OffsetDateTime plusNanos(long); 11919 method public java.time.OffsetTime plusNanos(long); 12149 method public java.time.ZonedDateTime plusNanos(long);
|