Websphere MQ Everyplace

examples.config
Class LocalQueueAdmin

java.lang.Object
  |
  +--examples.config.LocalQueueAdmin

public class LocalQueueAdmin
extends java.lang.Object

This class illustrates queue administrtion using admin messages.

It creates a local queue a local queue manager. This example will create a queue manager, open it, and create a local queue called 'NewQueue' on the local queue manager. Because the example is simple it assumes that the queue manager does not alreadfy exist. If the queue manager already exists before you run the example, then you will see an exception. Please delete the existing queue manager and try again....

The example will

It uses: CreateQueueManager to create and start a queue manager as an entry point to MQe, and as a subject of a queue manager query.

It uses BasicAdministration to handle the admin message


Field Summary
static short[] version
           
 
Constructor Summary
LocalQueueAdmin()
           
 
Method Summary
static void addLocalQueueAlias(MQeQueueManager localQueueManager, java.lang.String targetQueueManagerName, java.lang.String queueName, java.lang.String aliasName)
          Add an alias to a local queue using a queue manager to access the MQe Network.
static void createLocalQueue(MQeQueueManager localQueueManager, java.lang.String targetQueueManagerName, java.lang.String queueName)
          Create a local queue using a queue manager to access the MQe Network.
static void deleteLocalQueue(MQeQueueManager localQueueManager, java.lang.String targetQueueManagerName, java.lang.String queueName)
          Delete a local queue using a queue manager to access the MQe Network.
static void main(java.lang.String[] args)
           
static void removeLocalQueueAlias(MQeQueueManager localQueueManager, java.lang.String targetQueueManagerName, java.lang.String queueName, java.lang.String aliasName)
          Remove an alias from a local queue using a queue manager to access the MQe Network.
 
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
Constructor Detail

LocalQueueAdmin

public LocalQueueAdmin()
Method Detail

main

public static final void main(java.lang.String[] args)

createLocalQueue

public static final void createLocalQueue(MQeQueueManager localQueueManager,
                                          java.lang.String targetQueueManagerName,
                                          java.lang.String queueName)
                                   throws java.lang.Exception
Create a local queue using a queue manager to access the MQe Network. This routine will also create a local queue on a remote queue manager, but there maust be a path for the admin message to travel to the destination queue manager

java.lang.Exception

deleteLocalQueue

public static final void deleteLocalQueue(MQeQueueManager localQueueManager,
                                          java.lang.String targetQueueManagerName,
                                          java.lang.String queueName)
                                   throws java.lang.Exception
Delete a local queue using a queue manager to access the MQe Network. This routine will also delete a local queue on a remote queue manager, but there maust be a path for the admin message to travel to the destination queue manager

java.lang.Exception

addLocalQueueAlias

public static final void addLocalQueueAlias(MQeQueueManager localQueueManager,
                                            java.lang.String targetQueueManagerName,
                                            java.lang.String queueName,
                                            java.lang.String aliasName)
                                     throws java.lang.Exception
Add an alias to a local queue using a queue manager to access the MQe Network. This routine will also add an alias to a local queue on a remote queue manager, but there maust be a path for the admin message to travel to the destination queue manager

java.lang.Exception

removeLocalQueueAlias

public static final void removeLocalQueueAlias(MQeQueueManager localQueueManager,
                                               java.lang.String targetQueueManagerName,
                                               java.lang.String queueName,
                                               java.lang.String aliasName)
                                        throws java.lang.Exception
Remove an alias from a local queue using a queue manager to access the MQe Network. This routine will also remove an alias from a local queue on a remote queue manager, but there maust be a path for the admin message to travel to the destination queue manager

java.lang.Exception

Websphere MQ Everyplace