| Modifier and Type | Field and Description |
|---|---|
boolean |
running |
| Modifier and Type | Method and Description |
|---|---|
void |
asyncOperationComplete(MqttToken token) |
void |
connectionLost(MqttException cause)
This method is called when the connection to the server is lost.
|
protected boolean |
deliverMessage(String topicName,
int messageId,
MqttMessage aMessage) |
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 |
messageArrivedComplete(int messageId,
int qos) |
void |
quiesce()
Let the call back thread quiesce.
|
void |
removeMessageListener(String topicFilter) |
void |
removeMessageListeners() |
void |
run() |
void |
setCallback(MqttCallback mqttCallback) |
void |
setClientState(ClientState clientState) |
void |
setManualAcks(boolean manualAcks) |
void |
setMessageListener(String topicFilter,
IMqttMessageListener messageListener) |
void |
setReconnectCallback(MqttCallbackExtended callback) |
void |
start(String threadName,
ExecutorService executorService)
Starts up the Callback thread.
|
void |
stop()
Stops the callback thread.
|
public void setClientState(ClientState clientState)
public void start(String threadName, ExecutorService executorService)
public void stop()
public void setCallback(MqttCallback mqttCallback)
public void setReconnectCallback(MqttCallbackExtended callback)
public void setManualAcks(boolean manualAcks)
public 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 messageArrivedComplete(int messageId,
int qos)
throws MqttException
MqttExceptionpublic void asyncOperationComplete(MqttToken token)
protected Thread getThread()
public void setMessageListener(String topicFilter, IMqttMessageListener messageListener)
public void removeMessageListener(String topicFilter)
public void removeMessageListeners()
protected boolean deliverMessage(String topicName, int messageId, MqttMessage aMessage) throws Exception
ExceptionCopyright © 2018 Eclipse Paho. All Rights Reserved.