- Sort Score
- Result 10 results
- Languages All
Results 11 - 20 of 73 for duration (0.16 sec)
-
guava-tests/test/com/google/common/cache/CacheBuilderTest.java
} } @GwtIncompatible // java.time.Duration public void testTimeToLive_setTwice_duration() { CacheBuilder<Object, Object> builder = CacheBuilder.newBuilder().expireAfterWrite(java.time.Duration.ofSeconds(3600)); assertThrows( IllegalStateException.class, () -> builder.expireAfterWrite(java.time.Duration.ofSeconds(3600))); } public void testTimeToIdle_negative() {
Java - Registered: Fri Apr 19 12:43:09 GMT 2024 - Last Modified: Tue Oct 03 20:10:02 GMT 2023 - 25.5K bytes - Viewed (0) -
android/guava/src/com/google/common/util/concurrent/RateLimiter.java
* rate at the end of the period (as long as there are enough requests to saturate it). Similarly, * if the {@code RateLimiter} is left <i>unused</i> for a duration of {@code warmupPeriod}, it * will gradually return to its "cold" state, i.e. it will go through the same warming up process * as when it was first created. *
Java - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Tue Apr 04 09:45:04 GMT 2023 - 18.2K bytes - Viewed (0) -
guava-testlib/src/com/google/common/testing/FakeTicker.java
return this; } /** * Advances the ticker value by {@code duration}. * * @since 28.0 */ @GwtIncompatible @J2ktIncompatible @CanIgnoreReturnValue @SuppressWarnings("Java7ApiChecker") // guava-android can rely on library desugaring now. public FakeTicker advance(Duration duration) { return advance(duration.toNanos()); } /**
Java - Registered: Fri Apr 19 12:43:09 GMT 2024 - Last Modified: Tue Feb 06 14:40:46 GMT 2024 - 3.5K bytes - Viewed (0) -
guava-testlib/test/com/google/common/testing/FakeTickerTest.java
assertEquals(6000000000L, ticker.read()); } @GwtIncompatible // java.time.Duration @SuppressWarnings("Java7ApiChecker") // guava-android can rely on library desugaring now. public void testAutoIncrementStep_duration() { FakeTicker ticker = new FakeTicker().setAutoIncrementStep(Duration.ofMillis(1)); assertEquals(0, ticker.read()); assertEquals(1000000, ticker.read());
Java - Registered: Fri Apr 19 12:43:09 GMT 2024 - Last Modified: Tue Feb 06 14:40:46 GMT 2024 - 6.3K bytes - Viewed (0) -
guava-tests/test/com/google/common/base/SuppliersTest.java
} } @SuppressWarnings("Java7ApiChecker") // test of Java 8+ API @J2ktIncompatible // Duration @GwtIncompatible // Duration public void testMemoizeWithExpiration_durationNegative() throws InterruptedException { try { Supplier<String> unused = Suppliers.memoizeWithExpiration(() -> "", Duration.ZERO); fail(); } catch (IllegalArgumentException expected) { } try {
Java - Registered: Fri Apr 19 12:43:09 GMT 2024 - Last Modified: Fri Feb 09 15:49:48 GMT 2024 - 18.1K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/base/SuppliersTest.java
} } @SuppressWarnings("Java7ApiChecker") // test of Java 8+ API @J2ktIncompatible // Duration @GwtIncompatible // Duration public void testMemoizeWithExpiration_durationNegative() throws InterruptedException { try { Supplier<String> unused = Suppliers.memoizeWithExpiration(() -> "", Duration.ZERO); fail(); } catch (IllegalArgumentException expected) { } try {
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Fri Feb 09 15:49:48 GMT 2024 - 18.1K bytes - Viewed (0) -
android/guava/src/com/google/common/util/concurrent/Monitor.java
lock.lock(); } /** * Enters this monitor. Blocks at most the given time. * * @return whether the monitor was entered */ @SuppressWarnings("GoodTime") // should accept a java.time.Duration public boolean enter(long time, TimeUnit unit) { final long timeoutNanos = toSafeNanos(time, unit); final ReentrantLock lock = this.lock; if (!fair && lock.tryLock()) { return true; }
Java - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Mon Dec 04 18:22:01 GMT 2023 - 38.6K bytes - Viewed (0) -
android/guava/src/com/google/common/util/concurrent/Uninterruptibles.java
* uninterruptibly. */ @J2ktIncompatible @GwtIncompatible // concurrency @SuppressWarnings("GoodTime") // should accept a java.time.Duration public static boolean awaitUninterruptibly(CountDownLatch latch, long timeout, TimeUnit unit) { boolean interrupted = false; try { long remainingNanos = unit.toNanos(timeout);
Java - Registered: Fri Apr 26 12:43:10 GMT 2024 - Last Modified: Tue Apr 04 09:45:04 GMT 2023 - 14.4K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/ListeningExecutorServiceTest.java
String result = executorService.invokeAny(tasks, Duration.ofSeconds(7)); assertThat(result).isEqualTo("invokeAny"); assertThat(recordedTasks).isSameInstanceAs(tasks); assertThat(recordedTimeUnit).isEqualTo(NANOSECONDS); assertThat(Duration.ofNanos(recordedTimeout)).isEqualTo(Duration.ofSeconds(7)); } public void testInvokeAll() throws Exception {
Java - Registered: Fri Apr 12 12:43:09 GMT 2024 - Last Modified: Fri Jun 02 12:45:23 GMT 2023 - 4.5K bytes - Viewed (0) -
android/guava/src/com/google/common/cache/CacheBuilder.java
@CanIgnoreReturnValue public CacheBuilder<K, V> refreshAfterWrite(long duration, TimeUnit unit) { checkNotNull(unit); checkState(refreshNanos == UNSET_INT, "refresh was already set to %s ns", refreshNanos); checkArgument(duration > 0, "duration must be positive: %s %s", duration, unit); this.refreshNanos = unit.toNanos(duration); return this; }
Java - Registered: Fri May 03 12:43:13 GMT 2024 - Last Modified: Thu Feb 15 16:12:13 GMT 2024 - 44.8K bytes - Viewed (0)