|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.eclipse.paho.client.mqttv3.internal.CommsCallback
public class CommsCallback
Bridge between Receiver and the external API. This class gets called by Receiver, and then converts the comms-centric MQTT message objects into ones understood by the external API.
| Field Summary | |
|---|---|
boolean |
running
|
| Method Summary | |
|---|---|
void |
asyncOperationComplete(MqttToken token)
|
void |
connectionLost(MqttException cause)
This method is called when the connection to the server is lost. |
void |
fireActionEvent(MqttToken token)
An action has completed - if a completion listener has been set on the token then invoke it with the outcome of the action. |
protected Thread |
getThread()
Returns the thread used by this callback. |
boolean |
isQuiesced()
|
void |
messageArrived(MqttPublish sendMessage)
This method is called when a message arrives on a topic. |
void |
quiesce()
Let the call back thread quiesce. |
void |
run()
|
void |
setCallback(MqttCallback mqttCallback)
|
void |
setClientState(ClientState clientState)
|
void |
start(String threadName)
Starts up the Callback thread. |
void |
stop()
Stops the callback thread. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public boolean running
| Method Detail |
|---|
public void setClientState(ClientState clientState)
public void start(String threadName)
public void stop()
public void setCallback(MqttCallback mqttCallback)
public void run()
run in interface Runnablepublic void connectionLost(MqttException cause)
cause - the reason behind the loss of connection.public void fireActionEvent(MqttToken token)
token - public void messageArrived(MqttPublish sendMessage)
sendMessage - the MQTT SEND message.public void quiesce()
public boolean isQuiesced()
public void asyncOperationComplete(MqttToken token)
protected Thread getThread()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||