|
Websphere MQ Everyplace | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.ibm.mqe.MQe | +--examples.application.ExampleBase
Extends MQe, MQe base class.
To provide the base class/object for example applications.
Provides a set variables which are initialised with defaults values. The setParms method allows the values to be over-ridden. The accessLocalQMgr method starts the local queue manager. If the queue manager does not exist, a default queue manager is created and started. The meat of the example is placed in the doIt method.
The examples can run against queues on the local queue manager by using the default constructor or can run against a remote queue manager by using the constructor which takes a string parameter. To run against a remote queue manager, a remote queue manager defintion must be created on the local queue manager.
Field Summary | |
protected MQeClient |
client
|
protected java.lang.String |
example
|
protected java.lang.String |
localQMgrName
|
protected java.lang.String |
msgData
|
protected java.lang.String |
msgField
|
protected MQeQueueManager |
myQM
|
protected java.lang.String |
qMgrName
|
protected java.lang.String |
queueName
|
protected java.lang.String |
startupIni
|
static short[] |
version
|
Constructor Summary | |
ExampleBase()
Constructor that uses the default queue manager. |
|
ExampleBase(java.lang.String queueManagerName)
Constructor that runs the example against a remote queue manager. |
|
ExampleBase(java.lang.String remoteQMgrName,
java.lang.String localQMgrIniFile)
Constructor that starts a queue manager with paramters from an ini file. |
Method Summary | |
void |
accessLocalQMgr()
Start the local queue manager. |
void |
close()
Closes the client. |
abstract void |
doIt()
All work is performed in this method. |
void |
emptyQueue()
Remove any message from the queue used by the example. |
abstract void |
setParms()
Override any default variable settings here |
Methods inherited from class com.ibm.mqe.MQe |
abbreviate, alias, asciiToByte, byteToAscii, byteToHex, byteToHex, byteToInt, byteToLong, byteToShort, byteToUnicode, fileSeparator, getEventLogHandler, hexToAscii, hexToByte, intToByte, isCLDC, loadClass, loadObject, log, setEventLogHandler, setLoader, sliceByteArray, type, unicodeToByte, uniqueValue |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static short[] version
protected java.lang.String localQMgrName
protected java.lang.String startupIni
protected MQeQueueManager myQM
protected MQeClient client
protected java.lang.String qMgrName
protected java.lang.String example
protected java.lang.String queueName
protected java.lang.String msgField
protected java.lang.String msgData
Constructor Detail |
public ExampleBase() throws java.lang.Exception
java.lang.Exception
public ExampleBase(java.lang.String queueManagerName) throws java.lang.Exception
queueManagerName
- java.lang.String, remote queue manager name.
java.lang.Exception
public ExampleBase(java.lang.String remoteQMgrName, java.lang.String localQMgrIniFile) throws java.lang.Exception
remoteQMgrName
- java.lang.String , queue manager name
The name of the queue manager to interact with.
The queue manager can be either a local or a remote
queue manager.localQMgrIniFile
- java.lang.String, ini file which
contains startup parameters for the local queue
manager.
java.lang.Exception
Method Detail |
public void accessLocalQMgr() throws java.lang.Exception
java.lang.Exception
public void close() throws java.lang.Exception
java.lang.Exception
public abstract void doIt() throws java.lang.Exception
java.lang.Exception
public void emptyQueue() throws java.lang.Exception
java.lang.Exception
public abstract void setParms()
|
Websphere MQ Everyplace | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |