- Sort Score
- Result 10 results
- Languages All
Results 1 - 4 of 4 for newStartedThread (0.1 sec)
-
guava-tests/test/com/google/common/util/concurrent/AtomicDoubleArrayTest.java
for (int i = 0; i < SIZE; i++) { aa.set(i, (double) COUNTDOWN); } Counter c1 = new Counter(aa); Counter c2 = new Counter(aa); Thread t1 = newStartedThread(c1); Thread t2 = newStartedThread(c2); awaitTermination(t1); awaitTermination(t2); assertEquals(SIZE * COUNTDOWN, c1.counts + c2.counts); } /** a deserialized serialized array holds same values */
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Thu Oct 17 02:42:09 UTC 2024 - 14.6K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/AtomicDoubleTest.java
public void testCompareAndSetInMultipleThreads() throws Exception { final AtomicDouble at = new AtomicDouble(1.0); Thread t = newStartedThread( new CheckedRunnable() { @Override @SuppressWarnings("ThreadPriorityCheck") // doing our best to test for races public void realRun() {
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Thu Oct 17 02:42:09 UTC 2024 - 10.3K bytes - Viewed (0) -
android/guava-tests/test/com/google/common/util/concurrent/JSR166TestCase.java
*/ long millisElapsedSince(long startNanoTime) { return NANOSECONDS.toMillis(System.nanoTime() - startNanoTime); } /** Returns a new started daemon Thread running the given runnable. */ Thread newStartedThread(Runnable runnable) { Thread t = new Thread(runnable); t.setDaemon(true); t.start(); return t; } /**
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Thu Oct 17 02:42:09 UTC 2024 - 37.9K bytes - Viewed (0) -
guava-tests/test/com/google/common/util/concurrent/JSR166TestCase.java
*/ long millisElapsedSince(long startNanoTime) { return NANOSECONDS.toMillis(System.nanoTime() - startNanoTime); } /** Returns a new started daemon Thread running the given runnable. */ Thread newStartedThread(Runnable runnable) { Thread t = new Thread(runnable); t.setDaemon(true); t.start(); return t; } /**
Registered: Fri Nov 01 12:43:10 UTC 2024 - Last Modified: Thu Oct 17 02:42:09 UTC 2024 - 37.9K bytes - Viewed (0)