/libcore/ojluni/src/test/java/util/concurrent/tck/ |
D | TimeUnitTest.java | 145 DAYS.toNanos(t)); in testToNanos() 147 HOURS.toNanos(t)); in testToNanos() 149 MINUTES.toNanos(t)); in testToNanos() 151 SECONDS.toNanos(t)); in testToNanos() 153 MILLISECONDS.toNanos(t)); in testToNanos() 155 MICROSECONDS.toNanos(t)); in testToNanos() 157 NANOSECONDS.toNanos(t)); in testToNanos() 323 long ratio = x.toNanos(1) / y.toNanos(1); in testConvertSaturate() 349 MILLISECONDS.toNanos(Long.MAX_VALUE / 2)); in testToNanosSaturate() 351 MILLISECONDS.toNanos(-Long.MAX_VALUE / 3)); in testToNanosSaturate() [all …]
|
D | AbstractQueuedLongSynchronizerTest.java | 254 long nanosTimeout = MILLISECONDS.toNanos(timeoutMillis); in await() 282 long nanosTimeout = MILLISECONDS.toNanos(timeoutMillis); in assertAwaitTimesOut() 285 assertTrue(nanosRemaining > -MILLISECONDS.toNanos(LONG_DELAY_MS)); in assertAwaitTimesOut() 546 sync.tryAcquireNanos(MILLISECONDS.toNanos(2 * LONG_DELAY_MS)); in testTryAcquireNanos_Interruptible() 578 long nanos = MILLISECONDS.toNanos(timeoutMillis()); in testAcquireNanos_Timeout() 1183 long nanos = MILLISECONDS.toNanos(2 * LONG_DELAY_MS); 1224 long nanos = MILLISECONDS.toNanos(2 * LONG_DELAY_MS); 1247 long nanos = MILLISECONDS.toNanos(millis);
|
D | AbstractQueuedSynchronizerTest.java | 257 long nanosTimeout = MILLISECONDS.toNanos(timeoutMillis); in await() 285 long nanosTimeout = MILLISECONDS.toNanos(timeoutMillis); in assertAwaitTimesOut() 288 assertTrue(nanosRemaining > -MILLISECONDS.toNanos(LONG_DELAY_MS)); in assertAwaitTimesOut() 549 sync.tryAcquireNanos(MILLISECONDS.toNanos(2 * LONG_DELAY_MS)); in testTryAcquireNanos_Interruptible() 581 long nanos = MILLISECONDS.toNanos(timeoutMillis()); in testAcquireNanos_Timeout() 1186 long nanos = MILLISECONDS.toNanos(2 * LONG_DELAY_MS); 1227 long nanos = MILLISECONDS.toNanos(2 * LONG_DELAY_MS); 1250 long nanos = MILLISECONDS.toNanos(millis);
|
D | LockSupportTest.java | 86 LockSupport.parkNanos(MILLISECONDS.toNanos(millis)); in parkNanos() 105 MILLISECONDS.toNanos(millis)); in parkNanosBlocker()
|
/libcore/ojluni/src/main/java/java/util/concurrent/ |
D | TimeUnit.java | 78 public long toNanos(long d) { return d; } in toNanos() method 85 public long convert(long d, TimeUnit u) { return u.toNanos(d); } in convert() 93 public long toNanos(long d) { return x(d, C1/C0, MAX/(C1/C0)); } in toNanos() method 108 public long toNanos(long d) { return x(d, C2/C0, MAX/(C2/C0)); } in toNanos() method 123 public long toNanos(long d) { return x(d, C3/C0, MAX/(C3/C0)); } in toNanos() method 139 public long toNanos(long d) { return x(d, C4/C0, MAX/(C4/C0)); } in toNanos() method 155 public long toNanos(long d) { return x(d, C5/C0, MAX/(C5/C0)); } in toNanos() method 171 public long toNanos(long d) { return x(d, C6/C0, MAX/(C6/C0)); } in toNanos() method 238 public long toNanos(long duration) { in toNanos() method in TimeUnit
|
D | Semaphore.java | 415 return sync.tryAcquireSharedNanos(1, unit.toNanos(timeout)); in tryAcquire() 592 return sync.tryAcquireSharedNanos(permits, unit.toNanos(timeout)); in tryAcquire()
|
D | CountDownLatch.java | 278 return sync.tryAcquireSharedNanos(1, unit.toNanos(timeout)); in await()
|
D | AbstractExecutorService.java | 230 return doInvokeAny(tasks, true, unit.toNanos(timeout)); in invokeAny() 264 final long nanos = unit.toNanos(timeout); in invokeAll()
|
D | CyclicBarrier.java | 436 return dowait(true, unit.toNanos(timeout)); in await()
|
D | ScheduledThreadPoolExecutor.java | 521 return triggerTime(unit.toNanos((delay < 0) ? 0 : delay)); in triggerTime() 600 unit.toNanos(period), in scheduleAtFixedRate() 625 -unit.toNanos(delay), in scheduleWithFixedDelay() 1149 long nanos = unit.toNanos(timeout); in poll()
|
D | LinkedBlockingDeque.java | 410 long nanos = unit.toNanos(timeout); in offerFirst() 433 long nanos = unit.toNanos(timeout); in offerLast() 514 long nanos = unit.toNanos(timeout); in pollFirst() 532 long nanos = unit.toNanos(timeout); in pollLast()
|
D | ThreadPoolExecutor.java | 1338 this.keepAliveTime = unit.toNanos(keepAliveTime); in ThreadPoolExecutor() 1479 long nanos = unit.toNanos(timeout); in awaitTermination() 1731 long keepAliveTime = unit.toNanos(time); in setKeepAliveTime()
|
D | FutureTask.java | 205 (s = awaitDone(true, unit.toNanos(timeout))) <= COMPLETING) in get()
|
D | DelayQueue.java | 254 long nanos = unit.toNanos(timeout); in poll()
|
D | LinkedBlockingQueue.java | 376 long nanos = unit.toNanos(timeout); in offer() 459 long nanos = unit.toNanos(timeout); in poll()
|
/libcore/jsr166-tests/src/test/java/jsr166/ |
D | TimeUnitTest.java | 112 DAYS.toNanos(t)); in testToNanos() 114 HOURS.toNanos(t)); in testToNanos() 116 MINUTES.toNanos(t)); in testToNanos() 118 SECONDS.toNanos(t)); in testToNanos() 120 MILLISECONDS.toNanos(t)); in testToNanos() 122 MICROSECONDS.toNanos(t)); in testToNanos() 124 NANOSECONDS.toNanos(t)); in testToNanos() 295 MILLISECONDS.toNanos(Long.MAX_VALUE / 2)); in testToNanosSaturate() 297 MILLISECONDS.toNanos(-Long.MAX_VALUE / 3)); in testToNanosSaturate()
|
D | AbstractQueuedLongSynchronizerTest.java | 226 long nanosTimeout = MILLISECONDS.toNanos(timeoutMillis); in await() 254 long nanosTimeout = MILLISECONDS.toNanos(timeoutMillis); in assertAwaitTimesOut() 257 assertTrue(nanosRemaining > -MILLISECONDS.toNanos(LONG_DELAY_MS)); in assertAwaitTimesOut() 518 sync.tryAcquireNanos(MILLISECONDS.toNanos(2 * LONG_DELAY_MS)); in testTryAcquireNanos_Interruptible() 550 long nanos = MILLISECONDS.toNanos(timeoutMillis()); in testAcquireNanos_Timeout() 1155 long nanos = MILLISECONDS.toNanos(2 * LONG_DELAY_MS); 1196 long nanos = MILLISECONDS.toNanos(2 * LONG_DELAY_MS); 1219 long nanos = MILLISECONDS.toNanos(millis);
|
D | AbstractQueuedSynchronizerTest.java | 229 long nanosTimeout = MILLISECONDS.toNanos(timeoutMillis); in await() 257 long nanosTimeout = MILLISECONDS.toNanos(timeoutMillis); in assertAwaitTimesOut() 260 assertTrue(nanosRemaining > -MILLISECONDS.toNanos(LONG_DELAY_MS)); in assertAwaitTimesOut() 521 sync.tryAcquireNanos(MILLISECONDS.toNanos(2 * LONG_DELAY_MS)); in testTryAcquireNanos_Interruptible() 553 long nanos = MILLISECONDS.toNanos(timeoutMillis()); in testAcquireNanos_Timeout() 1158 long nanos = MILLISECONDS.toNanos(2 * LONG_DELAY_MS); 1199 long nanos = MILLISECONDS.toNanos(2 * LONG_DELAY_MS); 1222 long nanos = MILLISECONDS.toNanos(millis);
|
D | LockSupportTest.java | 62 LockSupport.parkNanos(MILLISECONDS.toNanos(millis)); in parkNanos() 81 MILLISECONDS.toNanos(millis)); in parkNanosBlocker()
|
/libcore/ojluni/src/main/java/java/lang/ |
D | Process.java | 190 long rem = unit.toNanos(timeout); in waitFor() 201 rem = unit.toNanos(timeout) - (System.nanoTime() - startTime); in waitFor()
|
/libcore/ojluni/src/main/java/java/nio/file/attribute/ |
D | FileTime.java | 318 return unit.toNanos(value - unit.convert(days, TimeUnit.DAYS)); in toExcessNanos() 320 return TimeUnit.SECONDS.toNanos(toInstant().getEpochSecond() in toExcessNanos()
|
/libcore/ojluni/src/main/java/java/util/concurrent/locks/ |
D | ReentrantLock.java | 451 return sync.tryAcquireNanos(1, unit.toNanos(timeout)); in tryLock()
|
D | ReentrantReadWriteLock.java | 873 return sync.tryAcquireSharedNanos(1, unit.toNanos(timeout)); in tryLock() 1122 return sync.tryAcquireNanos(1, unit.toNanos(timeout)); in tryLock()
|
/libcore/ojluni/src/test/java/nio/file/attribute/ |
D | FileTimeTest.java | 249 MILLISECONDS.toNanos(1000))) in main() 256 -MILLISECONDS.toNanos(1))) in main()
|
/libcore/ojluni/src/main/java/java/time/ |
D | Clock.java | 285 long tickNanos = tickDuration.toNanos(); in tick()
|