public interface IEsfMqttMasterClient
| Modifier and Type | Method and Description |
|---|---|
int |
controlSubscribe(java.lang.String topic,
int qos)
Subscribes to a topic with the MQtt broker.
|
boolean |
isConnected()
Returns an indication of whether the MQtt connection to the broker is
established.
|
int |
publish(java.lang.String topic,
byte[] payload,
int qos,
boolean retain)
Publishes a message to the MQtt broker.
|
int |
publish(java.lang.String assetId,
java.lang.String topic,
byte[] payload,
int qos,
boolean retain)
Publishes a message to the MQtt broker.
|
void |
registerCallback(IEsfMqttCallbackHandler esfMqttCallbackHandler)
Register an IEsfMqttCallback with the IEsfMqttClient.
|
void |
release()
Releases this handle to the master client.
|
int |
subscribe(com.eurotech.cloud.message.EdcSubscription subscription)
Subscribes to a topic with the MQtt broker.
|
int |
subscribe(com.eurotech.cloud.message.EdcSubscription[] subscriptions)
Subscribes to one or more topics with the MQtt broker.
|
int |
subscribe(java.lang.String assetId,
com.eurotech.cloud.message.EdcSubscription subscription)
Subscribes to a topic with the MQtt broker.
|
int |
subscribe(java.lang.String assetId,
com.eurotech.cloud.message.EdcSubscription[] subscriptions)
Subscribes to one or more topics with the MQtt broker.
|
int |
subscribe(java.lang.String topic,
int qos)
Subscribes to a topic with the MQtt broker.
|
int |
subscribe(java.lang.String assetId,
java.lang.String topic,
int qos)
Subscribes to a topic with the MQtt broker.
|
int |
unsubscribe(com.eurotech.cloud.message.EdcSubscription subscription)
Unsubscribes from a topic with the MQtt broker.
|
int |
unsubscribe(java.lang.String topic)
Unsubscribes from a topic with the MQtt broker.
|
int |
unsubscribe(java.lang.String assetId,
com.eurotech.cloud.message.EdcSubscription subscription)
Unsubscribes from a topic with the MQtt broker.
|
int |
unsubscribe(java.lang.String assetId,
java.lang.String topic)
Unsubscribes from a topic with the MQtt broker.
|
int publish(java.lang.String topic,
byte[] payload,
int qos,
boolean retain)
throws EsfMqttException
topic - A String specifying the topic the message was published on.payload - An array of bytes containing the payload of the message.qos - An integer specifying the quality of service the message was published on.retain - Whether or not the broker should retain the messageEsfMqttExceptionint publish(java.lang.String assetId,
java.lang.String topic,
byte[] payload,
int qos,
boolean retain)
throws EsfMqttException
assetId - A String specifying the asset ID.topic - A String specifying the topic the message was published on.payload - An array of bytes containing the payload of the message.qos - An integer specifying the quality of service the message was published on.retain - Whether or not the broker should retain the messageEsfMqttExceptionint subscribe(java.lang.String assetId,
com.eurotech.cloud.message.EdcSubscription[] subscriptions)
throws EsfMqttException
assetId - A String specifying the asset ID.subscriptions - An array of EdcSubscription objects.EsfMqttExceptionint subscribe(java.lang.String assetId,
com.eurotech.cloud.message.EdcSubscription subscription)
throws EsfMqttException
assetId - A String specifying the asset ID.subscription - An EdcSubscription object.EsfMqttExceptionint subscribe(java.lang.String assetId,
java.lang.String topic,
int qos)
throws EsfMqttException
assetId - A String specifying the asset ID.topic - A String object containing the topic.qos - An int containing the Quality of Service.EsfMqttExceptionint unsubscribe(java.lang.String assetId,
com.eurotech.cloud.message.EdcSubscription subscription)
throws EsfMqttException
assetId - A String specifying the asset ID.subscription - A EdcSubscription object containing the topic.EsfMqttExceptionint unsubscribe(java.lang.String assetId,
java.lang.String topic)
throws EsfMqttException
assetId - A String specifying the asset ID.topic - A String object containing the topic.EsfMqttExceptionint unsubscribe(com.eurotech.cloud.message.EdcSubscription subscription)
throws EsfMqttException
subscription - A EdcSubscription object containing the topic.EsfMqttExceptionint unsubscribe(java.lang.String topic)
throws EsfMqttException
topic - A String object containing the topic.EsfMqttExceptionint subscribe(com.eurotech.cloud.message.EdcSubscription[] subscriptions)
throws EsfMqttException
subscriptions - An array of EdcSubscription objects.EsfMqttExceptionint subscribe(com.eurotech.cloud.message.EdcSubscription subscription)
throws EsfMqttException
subscription - An EdcSubscription object.EsfMqttExceptionint subscribe(java.lang.String topic,
int qos)
throws EsfMqttException
topic - A String object containing the topic.qos - An int containing the Quality of Service.EsfMqttExceptionint controlSubscribe(java.lang.String topic,
int qos)
throws EsfMqttException
topic - A String object containing the topic.qos - An int containing the Quality of Service.EsfMqttExceptionboolean isConnected()
void registerCallback(IEsfMqttCallbackHandler esfMqttCallbackHandler)
esfMqttCallbackHandler - An implementation of the IEsfMqttCallbackHandler interface.void release()
Copyright © 2009 Eurotech Inc. All rights reserved.