xmlBlaster 2.2.0 API

org.xmlBlaster.test
Class Util

java.lang.Object
  extended by org.xmlBlaster.test.Util

public class Util
extends java.lang.Object

Some helper methods for test clients


Constructor Summary
Util()
           
 
Method Summary
static MsgUnit[] adminGet(Global glob, java.lang.String command)
          Do an administrative command to the server with a temporaty login session.
static void ask(java.lang.String text)
          Stop execution until a key is hit
static void delay(long millis)
          Stop execution for some given milliseconds
static void gc(int numGc)
          Do some garbage collect attempts
static java.lang.String[] getDefaultServerPorts()
          Reset the server ports to default, that a client in this JVM finds the server
static Global getOtherServerPorts(Global orig, int serverPort)
          If you want to start a second xmlBlaster instances set environment that the ports don't conflict
static java.lang.String[] getOtherServerPorts(int serverPort)
          If you want to start a second xmlBlaster instances set environment that the ports don't conflict
static java.lang.String[] getOtherServerPorts(int serverPort, java.lang.String[] others)
          If you want to start a second xmlBlaster instances set environment that the ports don't conflict
static java.util.Vector getOtherServerPortVec(int serverPort)
          If you want to start a second xmlBlaster instances set environment that the ports don't conflict
static void resetPorts()
           
static void resetPorts(Global glob)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Util

public Util()
Method Detail

getOtherServerPorts

public static Global getOtherServerPorts(Global orig,
                                         int serverPort)
If you want to start a second xmlBlaster instances set environment that the ports don't conflict

Returns:
A cloned Global which is configured with different serverPort

getOtherServerPorts

public static java.lang.String[] getOtherServerPorts(int serverPort)
If you want to start a second xmlBlaster instances set environment that the ports don't conflict


getOtherServerPorts

public static java.lang.String[] getOtherServerPorts(int serverPort,
                                                     java.lang.String[] others)
If you want to start a second xmlBlaster instances set environment that the ports don't conflict

Parameters:
others - Other params to add

getOtherServerPortVec

public static java.util.Vector getOtherServerPortVec(int serverPort)
If you want to start a second xmlBlaster instances set environment that the ports don't conflict


getDefaultServerPorts

public static java.lang.String[] getDefaultServerPorts()
Reset the server ports to default, that a client in this JVM finds the server


resetPorts

public static void resetPorts()

resetPorts

public static void resetPorts(Global glob)

delay

public static void delay(long millis)
Stop execution for some given milliseconds

Parameters:
millis - amount of milliseconds to wait

ask

public static void ask(java.lang.String text)
Stop execution until a key is hit

Parameters:
text - This text is shown on command line

gc

public static void gc(int numGc)
Do some garbage collect attempts


adminGet

public static MsgUnit[] adminGet(Global glob,
                                 java.lang.String command)
                          throws XmlBlasterException
Do an administrative command to the server with a temporaty login session.

Parameters:
command - "__sys__UserList" or "__cmd:/node/heron/?clientList"
Throws:
XmlBlasterException

xmlBlaster 2.2.0 API

Copyright © 1999-2014 The xmlBlaster.org contributers.