|
Websphere MQ Everyplace | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--examples.midp.exampleapp.msgpump.MsgPumpModel | +--examples.midp.exampleapp.msgpump.MsgPumpModelClient
This is the client implementation of the message pump model. What this means is that the logic required pump the messages to a server is located in this class. The actual implementation of that logic (creating and sending admin messages etc) is done in the Message Service. The interaction with the user is done by the controller, which also controls such things as where the messages are being pumped to and how fast.
Field Summary | |
static short[] |
version
|
Fields inherited from class examples.midp.exampleapp.msgpump.MsgPumpModel |
compressor, cryptor, DEFAULT_SECURITY, DEFAULT_SERVER_Q_NAME, DEFAULT_SERVER_QM_NAME, MESSAGE_SECURITY, NO_SECURITY, QUEUE_SECURITY, SECURITY_KEY, sync |
Method Summary | |
java.lang.String |
getServerAddress()
Gets the address that messages will be pumped to. |
java.lang.String |
getServerQMname()
Gets the name of the server's queue manager that is being pumped to. |
java.lang.String |
getServerQname()
Gets the name of the queue on the server that is being pumped to. |
long |
getWaitTime()
Get the wait time of the client. |
void |
pause()
Pauses the model. |
protected void |
performInitialConfiguration()
The client only requires a remote queue as it is not expecting to receive any messages. |
void |
processDataGramMsg(MQeMsgObject message,
java.lang.String qMgrName,
java.lang.String qName)
A datagram message has been received. |
void |
processReplyMsg(MQeMsgObject message,
java.lang.String qMgrName,
java.lang.String qName)
A reply message has been received. |
void |
processRequestMsg(MQeMsgObject message,
java.lang.String qMgrName,
java.lang.String qName)
A new request message has been received. |
void |
resume()
Resumes the model. |
void |
run()
The client of the message pump will send a message every [timeBetweenMsgs] milliseconds to the server until it is stopped or [maxMsgsToSend] messages have been sent. |
protected void |
setProperty(java.lang.String property,
java.lang.String value)
sets a property of the pump |
void |
setWaitTime(long wait)
Set how long the pump should wait between messages. |
void |
stop()
Called when something wants the model to stop. |
Methods inherited from class examples.midp.exampleapp.msgpump.MsgPumpModel |
createMessageAttribute, finish, getController, getLocalQMname, getMessageAttribute, getMsgService, getQMrules, getTimestamp, initialize, isSecurity, padNumber, processStatus, setController |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static short[] version
Method Detail |
protected void setProperty(java.lang.String property, java.lang.String value)
setProperty
in class MsgPumpModel
property
- The property to setvalue
- The value to set it to
public java.lang.String getServerAddress()
public void run()
public void stop()
MsgPumpModel
stop
in class MsgPumpModel
MsgPumpModel.stop()
public void pause()
MsgPumpModel
pause
in class MsgPumpModel
MsgPumpModel.pause()
public void resume()
MsgPumpModel
resume
in class MsgPumpModel
MsgPumpModel.resume()
public void setWaitTime(long wait)
wait
- Wait time in milliseconds
public long getWaitTime()
protected void performInitialConfiguration() throws java.lang.Exception
performInitialConfiguration
in class MsgPumpModel
java.lang.Exception
MsgPumpModel.performInitialConfiguration()
public void processDataGramMsg(MQeMsgObject message, java.lang.String qMgrName, java.lang.String qName)
MessageConsumer
message
- The message to displayqMgrName
- The queue manager the message is onqName
- The queue the message is on
MessageConsumer.processDataGramMsg(MQeMsgObject, String, String)
public void processReplyMsg(MQeMsgObject message, java.lang.String qMgrName, java.lang.String qName)
MessageConsumer
message
- The message to displayqMgrName
- The queue manager the message is onqName
- The queue the message is on
MessageConsumer.processReplyMsg(MQeMsgObject, String, String)
public void processRequestMsg(MQeMsgObject message, java.lang.String qMgrName, java.lang.String qName)
MessageConsumer
message
- The message to display.qMgrName
- The queue manager the message is onqName
- The queue the message is on
MessageConsumer.processRequestMsg(MQeMsgObject, String, String)
public java.lang.String getServerQMname()
public java.lang.String getServerQname()
|
Websphere MQ Everyplace | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |