CloudToDeviceMessageConnectionHandler Class
- java.
lang. Object - BaseHandler
- ErrorLoggingBaseHandler
- ErrorLoggingBaseHandlerWithCleanup
- AmqpConnectionHandler
- com.
microsoft. azure. sdk. iot. service. transport. amqps. CloudToDeviceMessageConnectionHandler
- com.
public class CloudToDeviceMessageConnectionHandler
Instance of the QPID-Proton-J BaseHandler class to override the events what are needed to handle the receive operation Contains and sets connection parameters (path, port, endpoint) Maintains the layers of AMQP protocol (Link, Session, Connection, Transport) Creates and sets SASL authentication for transport
Constructor Summary
Method Summary
Modifier and Type | Method and Description |
---|---|
void | closeAsync(Runnable onConnectionClosedCallback) |
boolean | isOpen() |
void | onAuthenticationSucceeded() |
void | onReactorFinal(Event event) |
void | onReceiverLinkRemoteOpen() |
void | onSenderLinkRemoteOpen() |
void | sendAsync(String deviceId, String moduleId, Message iotHubMessage, Consumer<SendResult> callback, Object context) |
Inherited Members
Constructor Details
CloudToDeviceMessageConnectionHandler
public CloudToDeviceMessageConnectionHandler(String hostName, AzureSasCredential azureSasCredential, IotHubServiceClientProtocol protocol, Consumer
Parameters:
CloudToDeviceMessageConnectionHandler
public CloudToDeviceMessageConnectionHandler(String connectionString, IotHubServiceClientProtocol protocol, Consumer
Parameters:
CloudToDeviceMessageConnectionHandler
public CloudToDeviceMessageConnectionHandler(String hostName, TokenCredential credential, IotHubServiceClientProtocol protocol, Consumer
Parameters:
Method Details
closeAsync
public void closeAsync(Runnable onConnectionClosedCallback)
Parameters:
isOpen
public boolean isOpen()
onAuthenticationSucceeded
public void onAuthenticationSucceeded()
onReactorFinal
public void onReactorFinal(Event event)
Parameters:
onReceiverLinkRemoteOpen
public void onReceiverLinkRemoteOpen()
onSenderLinkRemoteOpen
public void onSenderLinkRemoteOpen()
sendAsync
public void sendAsync(String deviceId, String moduleId, Message iotHubMessage, Consumer
Parameters:
Applies to
Azure SDK for Java