Package com.sun.sgs.app

Examples of com.sun.sgs.app.Channel.leaveAll()


    protected void leaveAll(final String channelName) throws Exception {
  txnScheduler.runTask(new TestAbstractKernelRunnable() {
      public void run() {
    Channel channel = getChannel(channelName);
    channel.leaveAll();
      }
  }, taskOwner);
    }

    protected void checkUsersJoined(
View Full Code Here


    @Test
    public void testChannelLeaveAllNoTxn() throws Exception {
  Channel channel = createChannel();
  try {
      channel.leaveAll();
      fail("Expected TransactionNotActiveException");
  } catch (TransactionNotActiveException e) {
      System.err.println(e);
  }
    }
View Full Code Here

      public void run() {
    Channel channel =
        channelService.createChannel("x", null, Delivery.RELIABLE);
    dataService.removeObject(channel);
    try {
        channel.leaveAll();
        fail("Expected IllegalStateException");
    } catch (IllegalStateException e) {
        System.err.println(e);
    }
      }
View Full Code Here

    public void testChannelLeaveAllNoSessionsJoined() throws Exception {
  txnScheduler.runTask(new TestAbstractKernelRunnable() {
      public void run() {
    Channel channel =
        channelService.createChannel("x", null, Delivery.RELIABLE);
    channel.leaveAll();
    System.err.println(
        "leaveAll succeeded with no sessions joined");
      }
  }, taskOwner);
    }
View Full Code Here

    @Test
    public void testChannelLeaveAllNoTxn() throws Exception {
  Channel channel = createChannel();
  try {
      channel.leaveAll();
      fail("Expected TransactionNotActiveException");
  } catch (TransactionNotActiveException e) {
      System.err.println(e);
  }
    }
View Full Code Here

      public void run() {
    Channel channel =
        channelService.createChannel("x", null, Delivery.RELIABLE);
    dataService.removeObject(channel);
    try {
        channel.leaveAll();
        fail("Expected IllegalStateException");
    } catch (IllegalStateException e) {
        System.err.println(e);
    }
      }
View Full Code Here

    public void testChannelLeaveAllNoSessionsJoined() throws Exception {
  txnScheduler.runTask(new TestAbstractKernelRunnable() {
      public void run() {
    Channel channel =
        channelService.createChannel("x", null, Delivery.RELIABLE);
    channel.leaveAll();
    System.err.println(
        "leaveAll succeeded with no sessions joined");
      }
  }, taskOwner);
    }
View Full Code Here

    @Test
    public void testChannelLeaveAllNoTxn() throws Exception {
  Channel channel = createChannel();
  try {
      channel.leaveAll();
      fail("Expected TransactionNotActiveException");
  } catch (TransactionNotActiveException e) {
      System.err.println(e);
  }
    }
View Full Code Here

      public void run() {
    Channel channel =
        channelService.createChannel("x", null, Delivery.RELIABLE);
    dataService.removeObject(channel);
    try {
        channel.leaveAll();
        fail("Expected IllegalStateException");
    } catch (IllegalStateException e) {
        System.err.println(e);
    }
      }
View Full Code Here

    public void testChannelLeaveAllNoSessionsJoined() throws Exception {
  txnScheduler.runTask(new TestAbstractKernelRunnable() {
      public void run() {
    Channel channel =
        channelService.createChannel("x", null, Delivery.RELIABLE);
    channel.leaveAll();
    System.err.println(
        "leaveAll succeeded with no sessions joined");
      }
  }, taskOwner);
    }
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.