Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 21 for Santos (0.21 sec)

  1. android/guava-tests/test/com/google/common/collect/IteratorsTest.java

        Iterable<String> list = Lists.newArrayList("cool", "pants");
        Iterator<String> iterator = list.iterator();
        assertEquals("pants", Iterators.find(iterator, Predicates.equalTo("pants")));
        assertFalse(iterator.hasNext());
      }
    
      public void testFind_notPresent() {
        Iterable<String> list = Lists.newArrayList("cool", "pants");
        Iterator<String> iterator = list.iterator();
        try {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Tue Apr 30 18:43:01 GMT 2024
    - 56.5K bytes
    - Viewed (0)
  2. guava-testlib/src/com/google/common/testing/FakeTicker.java

     *
     * <p>This class is thread-safe.
     *
     * @author Jige Yu
     * @since 10.0
     */
    @ElementTypesAreNonnullByDefault
    @GwtCompatible
    public class FakeTicker extends Ticker {
    
      private final AtomicLong nanos = new AtomicLong();
      private volatile long autoIncrementStepNanos;
    
      /** Advances the ticker value by {@code time} in {@code timeUnit}. */
      @SuppressWarnings("GoodTime") // should accept a java.time.Duration
    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)
  3. android/guava-tests/test/com/google/common/collect/IterablesTest.java

        assertTrue(Iterables.all(list, predicate));
        list.add("pants");
        assertFalse(Iterables.all(list, predicate));
      }
    
      public void testFind() {
        Iterable<String> list = newArrayList("cool", "pants");
        assertEquals("cool", Iterables.find(list, Predicates.equalTo("cool")));
        assertEquals("pants", Iterables.find(list, Predicates.equalTo("pants")));
        try {
          Iterables.find(list, Predicates.alwaysFalse());
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Mar 07 18:34:03 GMT 2024
    - 46K bytes
    - Viewed (0)
  4. guava/src/com/google/common/cache/CacheBuilder.java

      @SuppressWarnings("GoodTime") // should be a java.time.Duration
      private static final int DEFAULT_EXPIRATION_NANOS = 0;
    
      @SuppressWarnings("GoodTime") // should be a java.time.Duration
      private static final int DEFAULT_REFRESH_NANOS = 0;
    
      static final Supplier<? extends StatsCounter> NULL_STATS_COUNTER =
          Suppliers.ofInstance(
              new StatsCounter() {
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Feb 15 16:12:13 GMT 2024
    - 51.3K bytes
    - Viewed (0)
  5. android/guava/src/com/google/common/util/concurrent/Striped.java

     * itself is reclaimable. <i>Weak</i> means that locks/semaphores are created lazily, and they are
     * allowed to be reclaimed if nobody is holding on to them. This is useful, for example, if one
     * wants to create a {@code Striped<Lock>} of many locks, but worries that in most cases only a
     * small portion of these would be in use.
     *
     * <p>Prior to this class, one might be tempted to use {@code Map<K, Lock>}, where {@code K}
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 10 20:55:18 GMT 2023
    - 20.3K bytes
    - Viewed (1)
  6. guava/src/com/google/common/base/Stopwatch.java

        }
        if (HOURS.convert(nanos, NANOSECONDS) > 0) {
          return HOURS;
        }
        if (MINUTES.convert(nanos, NANOSECONDS) > 0) {
          return MINUTES;
        }
        if (SECONDS.convert(nanos, NANOSECONDS) > 0) {
          return SECONDS;
        }
        if (MILLISECONDS.convert(nanos, NANOSECONDS) > 0) {
          return MILLISECONDS;
        }
        if (MICROSECONDS.convert(nanos, NANOSECONDS) > 0) {
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Feb 23 15:09:35 GMT 2023
    - 9.2K bytes
    - Viewed (0)
  7. android/guava-testlib/test/com/google/common/testing/FakeTickerTest.java

      public void testAutoIncrementStep_returnsSameInstance() {
        FakeTicker ticker = new FakeTicker();
        assertSame(ticker, ticker.setAutoIncrementStep(10, TimeUnit.NANOSECONDS));
      }
    
      public void testAutoIncrementStep_nanos() {
        FakeTicker ticker = new FakeTicker().setAutoIncrementStep(10, TimeUnit.NANOSECONDS);
        assertEquals(0, ticker.read());
        assertEquals(10, ticker.read());
        assertEquals(20, ticker.read());
      }
    
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Tue Feb 06 14:40:46 GMT 2024
    - 6.4K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/util/concurrent/AbstractFuture.java

      // A heuristic for timed gets. If the remaining timeout is less than this, spin instead of
      // blocking. This value is what AbstractQueuedSynchronizer uses.
      private static final long SPIN_THRESHOLD_NANOS = 1000L;
    
      private static final AtomicHelper ATOMIC_HELPER;
    
      static {
        AtomicHelper helper;
        Throwable thrownUnsafeFailure = null;
        Throwable thrownAtomicReferenceFieldUpdaterFailure = null;
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 22 21:17:24 GMT 2024
    - 63K bytes
    - Viewed (0)
  9. android/guava-tests/test/com/google/common/util/concurrent/AbstractAbstractFutureTest.java

        long nanosPerSecond = NANOSECONDS.convert(1, SECONDS);
        assertThat(nanosPerSecond * Long.MAX_VALUE).isLessThan(0L);
    
        // Check that we wait long enough anyway (presumably as long as MAX_VALUE nanos):
        TimedWaiterThread waiter = new TimedWaiterThread(future, Long.MAX_VALUE, SECONDS);
        waiter.start();
        waiter.awaitWaiting();
    
        future.set(1);
        waiter.join();
      }
    
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Tue Feb 13 14:28:25 GMT 2024
    - 15.5K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/util/concurrent/OverflowAvoidingLockSupport.java

      private OverflowAvoidingLockSupport() {}
    
      static void parkNanos(@CheckForNull Object blocker, long nanos) {
        // Even in the extremely unlikely event that a thread unblocks itself early after only 68 years,
        // this is indistinguishable from a spurious wakeup, which LockSupport allows.
        LockSupport.parkNanos(blocker, min(nanos, MAX_NANOSECONDS_THRESHOLD));
      }
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Apr 04 09:45:04 GMT 2023
    - 1.6K bytes
    - Viewed (0)
Back to top