public abstract class MqttClient
extends org.eclipse.kapua.gateway.client.spi.AbstractClient
| Modifier and Type | Class and Description |
|---|---|
static class |
MqttClient.Builder<T extends MqttClient.Builder<T>> |
| Constructor and Description |
|---|
MqttClient(ScheduledExecutorService executor,
org.eclipse.kapua.gateway.client.BinaryPayloadCodec codec,
MqttNamespace namespace,
String clientId,
Set<org.eclipse.kapua.gateway.client.Module> modules) |
| Modifier and Type | Method and Description |
|---|---|
protected org.eclipse.kapua.gateway.client.BinaryPayloadCodec |
getCodec() |
String |
getMqttClientId() |
protected org.eclipse.kapua.gateway.client.spi.AbstractApplication |
internalCreateApplication(org.eclipse.kapua.gateway.client.Application.Builder builder,
String applicationId) |
protected void |
internalUnsubscribe(String applicationId,
Collection<org.eclipse.kapua.gateway.client.Topic> topics) |
protected void |
publish(String applicationId,
org.eclipse.kapua.gateway.client.Topic topic,
ByteBuffer buffer) |
abstract void |
publishMqtt(String topic,
ByteBuffer payload) |
protected CompletionStage<?> |
subscribe(String applicationId,
org.eclipse.kapua.gateway.client.Topic topic,
MqttMessageHandler messageHandler) |
protected abstract CompletionStage<?> |
subscribeMqtt(String topic,
MqttMessageHandler messageHandler) |
protected abstract void |
unsubscribeMqtt(Set<String> mqttTopics) |
buildApplication, handleApplicationClosed, handleConnected, handleDisconnected, internalBuildApplication, internalCloseApplication, notifyAddApplication, notifyConnected, notifyDisconnected, notifyRemoveApplication, transportclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitclosepublic MqttClient(ScheduledExecutorService executor, org.eclipse.kapua.gateway.client.BinaryPayloadCodec codec, MqttNamespace namespace, String clientId, Set<org.eclipse.kapua.gateway.client.Module> modules)
protected void publish(String applicationId, org.eclipse.kapua.gateway.client.Topic topic, ByteBuffer buffer) throws Exception
Exceptionpublic abstract void publishMqtt(String topic, ByteBuffer payload) throws Exception
Exceptionprotected abstract CompletionStage<?> subscribeMqtt(String topic, MqttMessageHandler messageHandler) throws Exception
Exceptionprotected CompletionStage<?> subscribe(String applicationId, org.eclipse.kapua.gateway.client.Topic topic, MqttMessageHandler messageHandler) throws Exception
Exceptionprotected void internalUnsubscribe(String applicationId, Collection<org.eclipse.kapua.gateway.client.Topic> topics) throws Exception
internalUnsubscribe in class org.eclipse.kapua.gateway.client.spi.AbstractClientExceptionprotected abstract void unsubscribeMqtt(Set<String> mqttTopics) throws Exception
Exceptionpublic String getMqttClientId()
protected org.eclipse.kapua.gateway.client.spi.AbstractApplication internalCreateApplication(org.eclipse.kapua.gateway.client.Application.Builder builder,
String applicationId)
internalCreateApplication in class org.eclipse.kapua.gateway.client.spi.AbstractClientprotected org.eclipse.kapua.gateway.client.BinaryPayloadCodec getCodec()
Copyright © 2017. All rights reserved.