Websphere MQ Everyplace

examples.mqbridge.administration.commandline
Class MQBridgeCreator

java.lang.Object
  |
  +--examples.administration.commandline.MQeAbstractCmdLineAdminTool
        |
        +--examples.mqbridge.administration.commandline.MQBridgeCreator

public class MQBridgeCreator
extends MQeAbstractCmdLineAdminTool

A command-line tool to add a bridge to a bridge-enabled queue manager.

Syntax

java examples.mqbridge.administration.commandline.MQBridgeCreator <bridgeName> <transformer> <qMgr> <iniFile>

Parameters

bridgeName
The name of the bridge to be created
transformer
The name of the class which will be used as the "default" transformer for converting between MQe and MQ message formats. Should include the .class extension. Could be an alias name of class also.
qMgr
The name of the queue manager to which the admin msg should be sent.
iniFile
The fully-qualified path name of the .ini file of the server queue manager.

Example

java ...MQBridgeCreator myBridge myTransformer.class MyQMgr C:\MQe\QMgrs\MyQMgr\MyQMgr.ini

Adds a bridge called "myBridge" to the MyQMgr queue manager.


Field Summary
static java.lang.String syntax
          Syntax of the command.
static short[] version
           
 
Fields inherited from class examples.administration.commandline.MQeAbstractCmdLineAdminTool
ADMIN_Q_NAME, REPLY_TO_Q, TIMEOUT_MILLISECS
 
Constructor Summary
MQBridgeCreator()
           
 
Method Summary
 void activate(java.lang.String[] args)
          Gathers the parameters and passes them to a method which does the command.
 void createMQBridge(java.lang.String bridgeName, java.lang.String transformerClass, java.lang.String targetQMgr, MQeQueueManager myQMgr)
          Creates an admin message which will create a bridge, and sends it to a named queue manager.
static void main(java.lang.String[] args)
          Entry point from the command line.
 
Methods inherited from class examples.administration.commandline.MQeAbstractCmdLineAdminTool
checkAdminReply, primeAdminMsg, processAdminMsg, sendWaitMessage
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

version

public static short[] version

syntax

public static final java.lang.String syntax
Syntax of the command.

See Also:
Constant Field Values
Constructor Detail

MQBridgeCreator

public MQBridgeCreator()
Method Detail

main

public static void main(java.lang.String[] args)
Entry point from the command line.


activate

public void activate(java.lang.String[] args)
              throws java.lang.Exception
Gathers the parameters and passes them to a method which does the command.

Parameters:
args -
Returns:
void
Throws:
java.lang.Exception

createMQBridge

public void createMQBridge(java.lang.String bridgeName,
                           java.lang.String transformerClass,
                           java.lang.String targetQMgr,
                           MQeQueueManager myQMgr)
                    throws java.lang.Exception
Creates an admin message which will create a bridge, and sends it to a named queue manager.

Parameters:
bridgeName - The name of the bridge to create
transformerClass - The name of the transformer class to set into the bridge configuration. This transformer will be used whenever a listener or bridge queue have a "" value in their transformer configuration parameters.
targetQMgr - The name of the MQe queue manager on which the bridge will be created.
myQMgr - A reference to an active MQe queue manager, used to send mesages from and receive messages using.
Returns:
void
Throws:
java.lang.Exception

Websphere MQ Everyplace