Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 10 of 28 for POST (0.14 sec)

  1. 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)
  2. android/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 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 17 15:19:38 GMT 2023
    - 1.6K bytes
    - Viewed (0)
  3. android/guava-tests/test/com/google/common/eventbus/outside/OutsideEventBusTest.java

              @Subscribe
              public void accept(String str) {
                holder.set(str);
                deliveries.incrementAndGet();
              }
            });
    
        String EVENT = "Hello!";
        bus.post(EVENT);
    
        assertEquals("Only one event should be delivered.", 1, deliveries.get());
        assertEquals("Correct string should be delivered.", EVENT, holder.get());
      }
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Tue May 15 20:25:06 GMT 2018
    - 1.8K bytes
    - Viewed (0)
  4. 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)
  5. 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)
  6. guava-tests/benchmark/com/google/common/collect/BinaryTreeTraverserBenchmark.java

          };
    
      enum Traversal {
        PRE_ORDER {
          @Override
          <T> Iterable<T> view(T root, TreeTraverser<T> viewer) {
            return viewer.preOrderTraversal(root);
          }
        },
        POST_ORDER {
          @Override
          <T> Iterable<T> view(T root, TreeTraverser<T> viewer) {
            return viewer.postOrderTraversal(root);
          }
        },
        BREADTH_FIRST {
          @Override
    Java
    - Registered: Fri Apr 19 12:43:09 GMT 2024
    - Last Modified: Tue Feb 26 19:18:53 GMT 2019
    - 4.9K bytes
    - Viewed (0)
  7. 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)
  8. 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)
  9. android/guava/src/com/google/common/collect/TreeTraverser.java

          if (childItr.hasNext()) {
            stack.addLast(childItr);
          }
          return result;
        }
      }
    
      /**
       * Returns an unmodifiable iterable over the nodes in a tree structure, using post-order
       * traversal. That is, each node's subtrees are traversed before the node itself is returned.
       *
       * <p>No guarantees are made about the behavior of the traversal when nodes change while iteration
    Java
    - Registered: Fri Apr 26 12:43:10 GMT 2024
    - Last Modified: Mon Apr 01 16:15:01 GMT 2024
    - 8.2K bytes
    - Viewed (0)
  10. 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)
Back to top