Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 40 for posts (0.68 sec)

  1. android/guava/src/com/google/common/eventbus/Dispatcher.java

       * all subscribers in the order they are posted.
       *
       * <p>When all subscribers are dispatched to using a <i>direct</i> executor (which dispatches on
       * the same thread that posts the event), this yields a breadth-first dispatch order on each
       * thread. That is, all subscribers to a single event A will be called before any subscribers to
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Fri Dec 15 19:31:54 GMT 2023
    - 7.3K bytes
    - Viewed (0)
  2. android/guava/src/com/google/common/eventbus/EventBus.java

       *
       * @param event event to post.
       */
      public void post(Object event) {
        Iterator<Subscriber> eventSubscribers = subscribers.getSubscribers(event);
        if (eventSubscribers.hasNext()) {
          dispatcher.dispatch(event, eventSubscribers);
        } else if (!(event instanceof DeadEvent)) {
          // the event had no subscribers and was not itself a DeadEvent
          post(new DeadEvent(this, event));
        }
      }
    
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Wed Aug 25 16:37:57 GMT 2021
    - 12.8K bytes
    - Viewed (0)
  3. guava-tests/test/com/google/common/eventbus/AsyncEventBusTest.java

        bus = new AsyncEventBus(executor);
      }
    
      public void testBasicDistribution() {
        StringCatcher catcher = new StringCatcher();
        bus.register(catcher);
    
        // We post the event, but our Executor will not deliver it until instructed.
        bus.post(EVENT);
    
        List<String> events = catcher.getEvents();
        assertTrue("No events should be delivered synchronously.", events.isEmpty());
    
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 2.3K bytes
    - Viewed (0)
  4. guava-tests/test/com/google/common/base/PredicatesTest.java

      @GwtIncompatible // SerializableTester
      public void testIsNull_serialization() {
        Predicate<String> pre = Predicates.isNull();
        Predicate<String> post = SerializableTester.reserializeAndAssert(pre);
        assertEquals(pre.apply("foo"), post.apply("foo"));
        assertEquals(pre.apply(null), post.apply(null));
      }
    
      public void testNotNull_apply() {
        Predicate<@Nullable Integer> notNull = Predicates.notNull();
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Thu Feb 22 17:15:24 GMT 2024
    - 32.4K bytes
    - Viewed (0)
  5. guava-tests/benchmark/com/google/common/eventbus/EventBusBenchmark.java

      void setUp() {
        eventBus = new EventBus("for benchmarking purposes");
        eventBus.register(this);
      }
    
      @Benchmark
      void postStrings(int reps) {
        for (int i = 0; i < reps; i++) {
          eventBus.post("hello there");
        }
      }
    
      @Subscribe
      public void handleStrings(String string) {
        // Nothing to do here.
      }
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Dec 04 17:37:03 GMT 2017
    - 1.2K bytes
    - Viewed (0)
  6. guava-tests/test/com/google/common/eventbus/outside/AbstractEventBusTest.java

        return subscriber;
      }
    
      @Override
      protected void setUp() throws Exception {
        subscriber = createSubscriber();
        EventBus bus = new EventBus();
        bus.register(subscriber);
        bus.post(EVENT);
      }
    
      @Override
      protected void tearDown() throws Exception {
        subscriber = null;
      }
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Mon Apr 17 15:19:38 GMT 2023
    - 1.6K bytes
    - Viewed (0)
  7. guava-testlib/pom.xml

          </plugin>
          <plugin>
            <artifactId>maven-source-plugin</artifactId>
            <executions>
              <execution>
                <id>attach-test-sources</id>
                <phase>post-integration-test</phase>
                <goals><goal>test-jar</goal></goals>
              </execution>
            </executions>
          </plugin>
          <plugin>
            <artifactId>maven-jar-plugin</artifactId>
    XML
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Jul 31 18:55:22 GMT 2023
    - 3.1K bytes
    - Viewed (0)
  8. android/guava-tests/pom.xml

          </plugin>
          <plugin>
            <artifactId>maven-source-plugin</artifactId>
            <executions>
              <execution>
                <id>attach-test-sources</id>
                <phase>post-integration-test</phase>
                <goals><goal>test-jar</goal></goals>
              </execution>
            </executions>
          </plugin>
          <plugin>
            <artifactId>maven-surefire-plugin</artifactId>
    XML
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Mon Aug 07 19:01:53 GMT 2023
    - 3.9K bytes
    - Viewed (0)
  9. guava/src/com/google/common/base/internal/Finalizer.java

     * loader as the rest of Guava, this thread would keep an indirect strong reference to the class
     * loader and prevent it from being garbage collected. This poses a problem for environments where
     * you want to throw away the class loader. For example, dynamically reloading a web application or
     * unloading an OSGi bundle.
     *
    Java
    - Registered: Fri Apr 05 12:43:09 GMT 2024
    - Last Modified: Wed Aug 23 12:54:09 GMT 2023
    - 9.4K bytes
    - Viewed (0)
  10. android/guava-tests/benchmark/com/google/common/util/concurrent/MonitorBasedPriorityBlockingQueue.java

       * collection-based APIs. Further, this method allows precise control over the runtime type of the
       * output array, and may, under certain circumstances, be used to save allocation costs.
       *
       * <p>Suppose {@code x} is a queue known to contain only strings. The following code can be used
       * to dump the queue into a newly allocated array of {@code String}:
       *
       * <pre>
    Java
    - Registered: Fri May 03 12:43:13 GMT 2024
    - Last Modified: Wed Apr 19 19:24:36 GMT 2023
    - 19.5K bytes
    - Viewed (0)
Back to top