Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 86 for listeners (0.17 sec)

  1. android/guava/src/com/google/common/util/concurrent/AbstractService.java

      }
    
      /** @since 13.0 */
      @Override
      public final void addListener(Listener listener, Executor executor) {
        listeners.addListener(listener, executor);
      }
    
      @Override
      public String toString() {
        return getClass().getSimpleName() + " [" + state() + "]";
      }
    
      /**
       * Attempts to execute all the listeners in {@link #listeners} while not holding the {@link
       * #monitor}.
       */
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri May 12 18:32:03 GMT 2023
    - 20.4K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/util/concurrent/AbstractFuture.java

        if (!isDone()) {
          Listener oldHead = listeners;
          if (oldHead != Listener.TOMBSTONE) {
            Listener newNode = new Listener(listener, executor);
            do {
              newNode.next = oldHead;
              if (ATOMIC_HELPER.casListeners(this, oldHead, newNode)) {
                return;
              }
              oldHead = listeners; // re-read
            } while (oldHead != Listener.TOMBSTONE);
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 22 21:17:24 GMT 2024
    - 63K bytes
    - Viewed (0)
  3. android/guava/src/com/google/common/util/concurrent/ExecutionList.java

     * instance contains a list of listeners, each with an associated {@code Executor}, and guarantees
     * that every {@code Runnable} that is {@linkplain #add added} will be executed after {@link
     * #execute()} is called. Any {@code Runnable} added after the call to {@code execute} is still
     * guaranteed to execute. There is no guarantee, however, that listeners will be executed in the
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 22 21:17:24 GMT 2024
    - 6.9K bytes
    - Viewed (0)
  4. guava-tests/test/com/google/common/util/concurrent/ListenableFutureTaskTest.java

        assertEquals(1, listenerLatch.getCount());
        assertFalse(task.isDone());
        assertFalse(task.isCancelled());
    
        // Finish the task by unblocking the task latch.  Then wait for the
        // listener to be called by blocking on the listener latch.
        taskLatch.countDown();
        assertEquals(25, task.get().intValue());
        assertTrue(listenerLatch.await(5, TimeUnit.SECONDS));
        assertTrue(task.isDone());
    Java
    - Registered: Fri Apr 12 12:43:09 GMT 2024
    - Last Modified: Wed Sep 06 17:04:31 GMT 2023
    - 4.7K bytes
    - Viewed (0)
  5. futures/listenablefuture1/src/com/google/common/util/concurrent/ListenableFuture.java

       * MoreExecutors#directExecutor}. Otherwise, avoid it: See the warnings on the docs for {@code
       * directExecutor}.
       *
       * <p>This is the most general listener interface. For common operations performed using
       * listeners, see {@link Futures}. For a simplified but general listener interface, see {@link
       * Futures#addCallback addCallback()}.
       *
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Jun 26 21:13:41 GMT 2023
    - 8K bytes
    - Viewed (0)
  6. android/guava/src/com/google/common/util/concurrent/Service.java

       * across calls to multiple listeners. Specifically, a given listener will have its callbacks
       * invoked in the same order as the underlying service enters those states. Additionally, at most
       * one of the listener's callbacks will execute at once. However, multiple listeners' callbacks
       * may execute concurrently, and listeners may execute in an order different from the one in which
       * they were registered.
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Apr 04 09:45:04 GMT 2023
    - 10.7K bytes
    - Viewed (0)
  7. android/guava/src/com/google/common/util/concurrent/ListenableFuture.java

       * MoreExecutors#directExecutor}. Otherwise, avoid it: See the warnings on the docs for {@code
       * directExecutor}.
       *
       * <p>This is the most general listener interface. For common operations performed using
       * listeners, see {@link Futures}. For a simplified but general listener interface, see {@link
       * Futures#addCallback addCallback()}.
       *
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Jun 26 21:13:41 GMT 2023
    - 8K bytes
    - Viewed (0)
  8. android/guava/src/com/google/common/util/concurrent/FluentFuture.java

       * the discussion in the {@link #addListener} documentation. All its warnings about heavyweight
       * listeners are also applicable to heavyweight callbacks passed to this method.
       *
       * <p>For a more general interface to attach a completion listener, see {@link #addListener}.
       *
       * <p>This method is similar to {@link java.util.concurrent.CompletableFuture#whenComplete} and
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue Apr 11 19:08:44 GMT 2023
    - 18.7K bytes
    - Viewed (0)
  9. guava-gwt/src-super/com/google/common/util/concurrent/super/com/google/common/util/concurrent/AbstractFuture.java

        checkNotNull(unit);
        return get();
      }
    
      @Override
      public void addListener(Runnable runnable, Executor executor) {
        Listener listener = new Listener(runnable, executor);
        if (isDone()) {
          listener.execute();
        } else {
          listeners.add(listener);
        }
      }
    
      @CanIgnoreReturnValue
      protected boolean setException(Throwable throwable) {
        checkNotNull(throwable);
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Jan 22 19:37:41 GMT 2024
    - 12.3K bytes
    - Viewed (0)
  10. android/guava/src/com/google/common/util/concurrent/ServiceManager.java

        }
    
        void enqueueStoppedEvent() {
          listeners.enqueue(STOPPED_EVENT);
        }
    
        void enqueueHealthyEvent() {
          listeners.enqueue(HEALTHY_EVENT);
        }
    
        void enqueueFailedEvent(final Service service) {
          listeners.enqueue(
              new ListenerCallQueue.Event<Listener>() {
                @Override
                public void call(Listener listener) {
                  listener.failure(service);
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Dec 13 19:45:20 GMT 2023
    - 30.5K bytes
    - Viewed (0)
Back to top