Examples of enableDelivery()


Examples of net.jini.event.MailboxRegistration.enableDelivery()

  }

  // Re-submit the listener1 to registration2 and
  // verify that it is not accepted
  try {
      mr2.enableDelivery(mbRel1);
      throw new TestException("Resubmission of mailbox "
          + "RemoteEventListener was accepted");
  } catch (IllegalArgumentException iae) {
      logger.log(Level.INFO, "Was not able to submit REL1 to MR2 - OK");
  }
View Full Code Here

Examples of net.jini.event.MailboxRegistration.enableDelivery()

  }

  // Re-submit the listener2 to registration2 and
  // verify that it is not accepted
  try {
      mr2.enableDelivery(mbRel2);
      throw new TestException("Resubmission of mailbox "
          + "RemoteEventListener was accepted");
  } catch (IllegalArgumentException iae) {
      logger.log(Level.INFO, "Was not able to submit REL2 to MR2 - OK");
  }
View Full Code Here

Examples of net.jini.event.MailboxRegistration.enableDelivery()

  // Pass our listener to the mailbox
  TestListener myRel = TestUtils.createListener(manager);
  mr1.enableDelivery(myRel);
  assertCount(myRel, 0);
  mr2.enableDelivery(myRel);
  assertCount(myRel, 0);
  logger.log(Level.INFO, "Submitted our own REL");

  // Re-submit listener again
  mr1.enableDelivery(myRel);
View Full Code Here

Examples of net.jini.event.MailboxRegistration.enableDelivery()

  logger.log(Level.INFO, "Submitted our own REL");

  // Re-submit listener again
  mr1.enableDelivery(myRel);
  assertCount(myRel, 0);
  mr2.enableDelivery(myRel);
  assertCount(myRel, 0);
  logger.log(Level.INFO, "Submitted our own REL again");

  // Submit the null listener
  mr2.enableDelivery(null);
View Full Code Here

Examples of net.jini.event.MailboxRegistration.enableDelivery()

  mr2.enableDelivery(myRel);
  assertCount(myRel, 0);
  logger.log(Level.INFO, "Submitted our own REL again");

  // Submit the null listener
  mr2.enableDelivery(null);
  assertCount(myRel, 0);
  mr1.enableDelivery(null);
  assertCount(myRel, 0);
  logger.log(Level.INFO, "Submitted a null REL");
View Full Code Here

Examples of net.jini.event.MailboxRegistration.enableDelivery()

  assertCount(myRel, 0);
  logger.log(Level.INFO, "Disabled delivery");

  mr1.enableDelivery(myRel);
  assertCount(myRel, 0);
  mr2.enableDelivery(myRel);
  assertCount(myRel, 0);
  logger.log(Level.INFO, "Submitted our own REL again");
 
  mr1.disableDelivery();
  assertCount(myRel, 0);
View Full Code Here

Examples of net.jini.event.MailboxRegistration.enableDelivery()

  };

  // Enable the first of our listener objects
  assertCount(myListener, eventCount);
  logger.log(Level.INFO, "Enabling delivery to our REL" + myListener);
  mr.enableDelivery(myListener);

        // Add an extra delay here since we'll only block
  // on the receipt of one event, but we really want
  // to see if a second event is sent as well.
  logger.log(Level.INFO, "sleeping for 5 sec");
View Full Code Here

Examples of net.jini.event.MailboxRegistration.enableDelivery()

  shutdown(0);

  // Enable the first of our listener objects
  // Enable good listener
  logger.log(Level.INFO, "Enabling good listener");
  mr.enableDelivery(goodListener);

  goodCount = 5;
  logger.log(Level.INFO, "Wating for event delivery of " + goodCount);
        waitForEvents(goodListener, goodCount, MAX_WAIT);
  logger.log(Level.INFO, "Asserting event count");
View Full Code Here

Examples of org.rioproject.eventcollector.api.EventCollectorRegistration.enableDelivery()

        Assert.assertEquals(1, eventCollectorImpl.getRegistrationSize());
        tearDownEventCollector();
        createEventCollector();
        BasicEventListener listener = new BasicEventListener();
        System.out.println("===> enableDelivery()");
        registration.enableDelivery(listener.export());
        System.out.println("===> getLease()");
        registration.getLease().cancel();
    }

    @Test(expected = UnknownEventCollectorRegistration.class)
View Full Code Here

Examples of org.rioproject.eventcollector.api.EventCollectorRegistration.enableDelivery()

        EventCollectorRegistration registration = eventCollector.register(Lease.FOREVER);
        verifyRegistration(registration);
        Assert.assertEquals(1, eventCollectorImpl.getRegistrationSize());
        BasicEventListener listener = new BasicEventListener();
        registration.getLease().cancel();
        registration.enableDelivery(listener.export());
    }

    @Test(expected = UnknownEventCollectorRegistration.class)
    public void testUnknownEventCollectorRegistration() throws UnknownEventCollectorRegistration, IOException {
        EventCollectorRegistration unknownRegistration = new Registration(eventCollectorImpl,
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.