Package net.sf.clairv.p2p.util

Examples of net.sf.clairv.p2p.util.Counter.decrement()


    final Counter counter = new Counter(1);
    this.endpoint.route(id, message, null, new DeliveryNotification() {

      public void sendFailed(MessageReceipt arg0, Exception arg1) {
        log.warn("Failed to send the message");
        counter.decrement();
      }

      public void sent(MessageReceipt receipt) {
        counter.decrement();
      }
View Full Code Here


        log.warn("Failed to send the message");
        counter.decrement();
      }

      public void sent(MessageReceipt receipt) {
        counter.decrement();
      }

    });
    while (counter.getValue() == 1) {
View Full Code Here

        final Counter counter = new Counter(1);
        endpoint.route(null, message, nh, new DeliveryNotification() {

          public void sendFailed(MessageReceipt arg0, Exception arg1) {
            log.warn("Failed to directly send a message", arg1);
            counter.decrement();
          }

          public void sent(MessageReceipt arg0) {
            counter.decrement();
          }
View Full Code Here

            log.warn("Failed to directly send a message", arg1);
            counter.decrement();
          }

          public void sent(MessageReceipt arg0) {
            counter.decrement();
          }

        });
        while (counter.getValue() == 1) {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.