Searched refs:negated (Results 1 - 6 of 6) sorted by relevance
/libcore/ojluni/src/main/java/java/time/chrono/ |
H A D | ChronoPeriod.java | 244 * Returns a new instance with each amount in this period negated. 246 * This returns a period with each supported unit individually negated. 248 * negated to "-2 years, 3 months and -4 days". 251 * @return a {@code ChronoPeriod} based on this period with the amounts negated, not null 255 default ChronoPeriod negated() { method in interface:ChronoPeriod
|
/libcore/ojluni/src/test/java/time/tck/java/time/ |
H A D | TCKDuration.java | 651 assertEquals(test, Duration.ofSeconds(expectedSeconds, expectedNanoOfSecond).negated()); 785 assertEquals(Duration.between(end, start), Duration.between(start, end).negated()); 805 assertEquals(Duration.between(end, start), Duration.between(start, end).negated()); 844 assertEquals(Duration.between(end, start), Duration.between(start, end).negated()); 2375 // negated() 2379 assertEquals(Duration.ofSeconds(0).negated(), Duration.ofSeconds(0)); 2380 assertEquals(Duration.ofSeconds(12).negated(), Duration.ofSeconds(-12)); 2381 assertEquals(Duration.ofSeconds(-12).negated(), Duration.ofSeconds(12)); 2382 assertEquals(Duration.ofSeconds(12, 20).negated(), Duration.ofSeconds(-12, -20)); 2383 assertEquals(Duration.ofSeconds(12, -20).negated(), Duratio [all...] |
H A D | TCKPeriod.java | 362 assertEquals(p, expected.negated()); 932 // negated() 936 assertPeriod(Period.of(0, 0, 0).negated(), 0 ,0, 0); 937 assertPeriod(Period.of(1, 2, 3).negated(), -1, -2, -3); 938 assertPeriod(Period.of(-1, -2, -3).negated(), 1, 2, 3); 939 assertPeriod(Period.of(-1, 2, -3).negated(), 1, -2, 3); 940 assertPeriod(Period.of(Integer.MAX_VALUE, Integer.MAX_VALUE, Integer.MAX_VALUE).negated(), 946 Period.ofYears(Integer.MIN_VALUE).negated(); 951 Period.ofMonths(Integer.MIN_VALUE).negated(); 956 Period.ofDays(Integer.MIN_VALUE).negated(); [all...] |
/libcore/ojluni/src/main/java/java/time/ |
H A D | Duration.java | 345 * or positive symbol. If negative, the whole period is negated. 438 return ofSeconds(seconds, nanos).negated(); 1007 * Returns a copy of this duration with the length negated. 1014 * @return a {@code Duration} based on this duration with the amount negated, not null 1017 public Duration negated() { method in class:Duration 1033 return isNegative() ? negated() : this;
|
H A D | Period.java | 290 * or positive symbol. If negative, the whole period is negated. 793 * Returns a new instance with each amount in this period negated. 796 * individually negated. 798 * negated to "-2 years, 3 months and -4 days". 801 * @return a {@code Period} based on this period with the amounts negated, not null 805 public Period negated() { method in class:Period
|
/libcore/ojluni/src/test/java/time/tck/java/time/chrono/ |
H A D | TCKChronoPeriod.java | 240 assertEquals(period.negated(), chrono.period(-1, -2, -3));
|
Completed in 337 milliseconds