Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 186 for references (0.39 sec)

  1. android/guava-testlib/src/com/google/common/testing/GcFinalization.java

       *   <li>clearing weak references to unreachable referents
       *   <li>enqueuing weak references to unreachable referents in their reference queue
       * </ul>
       */
      @DoNotMock("Implement with a lambda")
      public interface FinalizationPredicate {
        boolean isDone();
      }
    
      /**
       * Waits until the given weak reference is cleared, invoking the garbage collector as necessary to
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Feb 22 17:40:56 GMT 2024
    - 11.6K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/base/internal/Finalizer.java

        }
      }
    
      /**
       * Cleans up the given reference and any other references already in the queue. Catches and logs
       * all throwables.
       *
       * @return true if the caller should continue to wait for more references to be added to the
       *     queue, false if the associated FinalizableReferenceQueue is no longer referenced.
       */
      private boolean cleanUp(Reference<?> firstReference) {
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Aug 23 12:54:09 GMT 2023
    - 9.4K bytes
    - Viewed (0)
  3. guava-testlib/src/com/google/common/testing/GcFinalization.java

       *   <li>clearing weak references to unreachable referents
       *   <li>enqueuing weak references to unreachable referents in their reference queue
       * </ul>
       */
      @DoNotMock("Implement with a lambda")
      public interface FinalizationPredicate {
        boolean isDone();
      }
    
      /**
       * Waits until the given weak reference is cleared, invoking the garbage collector as necessary to
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu Feb 22 17:40:56 GMT 2024
    - 11.6K bytes
    - Viewed (0)
  4. guava-tests/test/com/google/common/base/EnumsTest.java

      }
    
      public void testGetIfPresent_whenNoMatchingConstant() {
        assertThat(Enums.getIfPresent(TestEnum.class, "WOMBAT")).isAbsent();
      }
    
    
      @J2ktIncompatible
      @GwtIncompatible // weak references
      @AndroidIncompatible // depends on details of GC and classloading
      public void testGetIfPresent_doesNotPreventClassUnloading() throws Exception {
        WeakReference<?> shadowLoaderReference = doTestClassUnloading();
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Tue Oct 03 20:10:02 GMT 2023
    - 8.8K bytes
    - Viewed (0)
  5. guava/src/com/google/common/base/Predicate.java

     * predicate::test}.
     *
     * <p>This interface is now a legacy type. Use {@code java.util.function.Predicate} (or the
     * appropriate primitive specialization such as {@code IntPredicate}) instead whenever possible.
     * Otherwise, at least reduce <i>explicit</i> dependencies on this type by using lambda expressions
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Thu Feb 15 16:12:13 GMT 2024
    - 3.5K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/base/FinalizableReference.java

    import com.google.errorprone.annotations.DoNotMock;
    
    /**
     * Implemented by references that have code to run after garbage collection of their referents.
     *
     * @see FinalizableReferenceQueue
     * @author Bob Lee
     * @since 2.0
     */
    @DoNotMock("Use an instance of one of the Finalizable*Reference classes")
    @J2ktIncompatible
    @GwtIncompatible
    @ElementTypesAreNonnullByDefault
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Feb 23 15:09:35 GMT 2023
    - 1.4K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/util/concurrent/AggregateFutureState.java

          /*
           * Using weak references here could let us release exceptions earlier, but:
           *
           * 1. On Android, querying a WeakReference blocks if the GC is doing an otherwise-concurrent
           * pass.
           *
           * 2. We would probably choose to compare exceptions using == instead of equals() (for
           * consistency with how weak references are cleared). That's a behavior change -- arguably the
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Thu Dec 14 20:35:03 GMT 2023
    - 8.5K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/base/Predicate.java

     * or method references instead of classes, leaving your code easier to migrate in the future.
     *
     * <p>To use a reference of this type (say, named {@code guavaPredicate}) in a context where {@code
     * java.util.function.Predicate} is expected, use the method reference {@code
     * guavaPredicate::apply}. For the other direction, use {@code javaUtilPredicate::test}. A future
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Thu Feb 15 16:12:13 GMT 2024
    - 3.6K bytes
    - Viewed (0)
  9. android/guava-tests/test/com/google/common/collect/AbstractIteratorTest.java

          fail("peek() should still throw NoSuchElementException after next()");
        } catch (NoSuchElementException expected) {
        }
      }
    
    
      @J2ktIncompatible // weak references, details of GC
      @GwtIncompatible // weak references
      @AndroidIncompatible // depends on details of GC
      public void testFreesNextReference() {
        Iterator<Object> itr =
            new AbstractIterator<Object>() {
              @Override
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Feb 21 10:16:44 GMT 2024
    - 8.7K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/collect/MapMaker.java

    import java.util.concurrent.ConcurrentMap;
    import javax.annotation.CheckForNull;
    
    /**
     * A builder of {@link ConcurrentMap} instances that can have keys or values automatically wrapped
     * in {@linkplain WeakReference weak} references.
     *
     * <p>Usage example:
     *
     * <pre>{@code
     * ConcurrentMap<Request, Stopwatch> timers = new MapMaker()
     *     .concurrencyLevel(4)
     *     .weakKeys()
     *     .makeMap();
     * }</pre>
     *
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Mar 13 14:30:51 GMT 2023
    - 12.8K bytes
    - Viewed (0)
Back to top