AWS IoT Device SDK C++ v2  1.34.0
AWS IoT Device SDK C++ v2
Public Member Functions | List of all members
Aws::Iotshadow::IotShadowClient Class Referencefinal

#include <IotShadowClient.h>

Public Member Functions

 IotShadowClient (const std::shared_ptr< Aws::Crt::Mqtt::MqttConnection > &connection)
 
 IotShadowClient (const std::shared_ptr< Aws::Crt::Mqtt5::Mqtt5Client > &mqtt5Client)
 
 operator bool () const noexcept
 
int GetLastError () const noexcept
 
bool SubscribeToDeleteNamedShadowAccepted (const Aws::Iotshadow::DeleteNamedShadowSubscriptionRequest &request, Aws::Crt::Mqtt::QOS qos, const OnSubscribeToDeleteNamedShadowAcceptedResponse &handler, const OnSubscribeComplete &onSubAck)
 
bool SubscribeToDeleteNamedShadowRejected (const Aws::Iotshadow::DeleteNamedShadowSubscriptionRequest &request, Aws::Crt::Mqtt::QOS qos, const OnSubscribeToDeleteNamedShadowRejectedResponse &handler, const OnSubscribeComplete &onSubAck)
 
bool SubscribeToDeleteShadowAccepted (const Aws::Iotshadow::DeleteShadowSubscriptionRequest &request, Aws::Crt::Mqtt::QOS qos, const OnSubscribeToDeleteShadowAcceptedResponse &handler, const OnSubscribeComplete &onSubAck)
 
bool SubscribeToDeleteShadowRejected (const Aws::Iotshadow::DeleteShadowSubscriptionRequest &request, Aws::Crt::Mqtt::QOS qos, const OnSubscribeToDeleteShadowRejectedResponse &handler, const OnSubscribeComplete &onSubAck)
 
bool SubscribeToGetNamedShadowAccepted (const Aws::Iotshadow::GetNamedShadowSubscriptionRequest &request, Aws::Crt::Mqtt::QOS qos, const OnSubscribeToGetNamedShadowAcceptedResponse &handler, const OnSubscribeComplete &onSubAck)
 
bool SubscribeToGetNamedShadowRejected (const Aws::Iotshadow::GetNamedShadowSubscriptionRequest &request, Aws::Crt::Mqtt::QOS qos, const OnSubscribeToGetNamedShadowRejectedResponse &handler, const OnSubscribeComplete &onSubAck)
 
bool SubscribeToGetShadowAccepted (const Aws::Iotshadow::GetShadowSubscriptionRequest &request, Aws::Crt::Mqtt::QOS qos, const OnSubscribeToGetShadowAcceptedResponse &handler, const OnSubscribeComplete &onSubAck)
 
bool SubscribeToGetShadowRejected (const Aws::Iotshadow::GetShadowSubscriptionRequest &request, Aws::Crt::Mqtt::QOS qos, const OnSubscribeToGetShadowRejectedResponse &handler, const OnSubscribeComplete &onSubAck)
 
bool SubscribeToNamedShadowDeltaUpdatedEvents (const Aws::Iotshadow::NamedShadowDeltaUpdatedSubscriptionRequest &request, Aws::Crt::Mqtt::QOS qos, const OnSubscribeToNamedShadowDeltaUpdatedEventsResponse &handler, const OnSubscribeComplete &onSubAck)
 
bool SubscribeToNamedShadowUpdatedEvents (const Aws::Iotshadow::NamedShadowUpdatedSubscriptionRequest &request, Aws::Crt::Mqtt::QOS qos, const OnSubscribeToNamedShadowUpdatedEventsResponse &handler, const OnSubscribeComplete &onSubAck)
 
bool SubscribeToShadowDeltaUpdatedEvents (const Aws::Iotshadow::ShadowDeltaUpdatedSubscriptionRequest &request, Aws::Crt::Mqtt::QOS qos, const OnSubscribeToShadowDeltaUpdatedEventsResponse &handler, const OnSubscribeComplete &onSubAck)
 
bool SubscribeToShadowUpdatedEvents (const Aws::Iotshadow::ShadowUpdatedSubscriptionRequest &request, Aws::Crt::Mqtt::QOS qos, const OnSubscribeToShadowUpdatedEventsResponse &handler, const OnSubscribeComplete &onSubAck)
 
bool SubscribeToUpdateNamedShadowAccepted (const Aws::Iotshadow::UpdateNamedShadowSubscriptionRequest &request, Aws::Crt::Mqtt::QOS qos, const OnSubscribeToUpdateNamedShadowAcceptedResponse &handler, const OnSubscribeComplete &onSubAck)
 
bool SubscribeToUpdateNamedShadowRejected (const Aws::Iotshadow::UpdateNamedShadowSubscriptionRequest &request, Aws::Crt::Mqtt::QOS qos, const OnSubscribeToUpdateNamedShadowRejectedResponse &handler, const OnSubscribeComplete &onSubAck)
 
bool SubscribeToUpdateShadowAccepted (const Aws::Iotshadow::UpdateShadowSubscriptionRequest &request, Aws::Crt::Mqtt::QOS qos, const OnSubscribeToUpdateShadowAcceptedResponse &handler, const OnSubscribeComplete &onSubAck)
 
bool SubscribeToUpdateShadowRejected (const Aws::Iotshadow::UpdateShadowSubscriptionRequest &request, Aws::Crt::Mqtt::QOS qos, const OnSubscribeToUpdateShadowRejectedResponse &handler, const OnSubscribeComplete &onSubAck)
 
bool PublishDeleteNamedShadow (const Aws::Iotshadow::DeleteNamedShadowRequest &request, Aws::Crt::Mqtt::QOS qos, const OnPublishComplete &onPubAck)
 
bool PublishDeleteShadow (const Aws::Iotshadow::DeleteShadowRequest &request, Aws::Crt::Mqtt::QOS qos, const OnPublishComplete &onPubAck)
 
bool PublishGetNamedShadow (const Aws::Iotshadow::GetNamedShadowRequest &request, Aws::Crt::Mqtt::QOS qos, const OnPublishComplete &onPubAck)
 
bool PublishGetShadow (const Aws::Iotshadow::GetShadowRequest &request, Aws::Crt::Mqtt::QOS qos, const OnPublishComplete &onPubAck)
 
bool PublishUpdateNamedShadow (const Aws::Iotshadow::UpdateNamedShadowRequest &request, Aws::Crt::Mqtt::QOS qos, const OnPublishComplete &onPubAck)
 
bool PublishUpdateShadow (const Aws::Iotshadow::UpdateShadowRequest &request, Aws::Crt::Mqtt::QOS qos, const OnPublishComplete &onPubAck)
 

Detailed Description

The AWS IoT Device Shadow service adds shadows to AWS IoT thing objects. Shadows are a simple data store for device properties and state. Shadows can make a device’s state available to apps and other services whether the device is connected to AWS IoT or not.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html

Constructor & Destructor Documentation

◆ IotShadowClient() [1/2]

Aws::Iotshadow::IotShadowClient::IotShadowClient ( const std::shared_ptr< Aws::Crt::Mqtt::MqttConnection > &  connection)

◆ IotShadowClient() [2/2]

Aws::Iotshadow::IotShadowClient::IotShadowClient ( const std::shared_ptr< Aws::Crt::Mqtt5::Mqtt5Client > &  mqtt5Client)

Member Function Documentation

◆ GetLastError()

int Aws::Iotshadow::IotShadowClient::GetLastError ( ) const
noexcept

◆ operator bool()

Aws::Iotshadow::IotShadowClient::operator bool ( ) const
noexcept

◆ PublishDeleteNamedShadow()

bool Aws::Iotshadow::IotShadowClient::PublishDeleteNamedShadow ( const Aws::Iotshadow::DeleteNamedShadowRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnPublishComplete onPubAck 
)

Deletes a named shadow for an AWS IoT thing.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#delete-pub-sub-topic

Publish a DeleteNamedShadow message. If the device is offline, the PUBLISH packet will be sent once the connection resumes.

Parameters
requestMessage to be serialized and sent
qosQuality of Service for delivering this message
onPubAckcallback when the publish "completes" (see below)
Returns
true if the message was successfully queued for publication, false if there was an error
  • For QoS 0, completes as soon as the packet is sent.
  • For QoS 1, completes when PUBACK is received.
  • QoS 2 is not supported by AWS IoT.

◆ PublishDeleteShadow()

bool Aws::Iotshadow::IotShadowClient::PublishDeleteShadow ( const Aws::Iotshadow::DeleteShadowRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnPublishComplete onPubAck 
)

Deletes the (classic) shadow for an AWS IoT thing.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#delete-pub-sub-topic

Publish a DeleteShadow message. If the device is offline, the PUBLISH packet will be sent once the connection resumes.

Parameters
requestMessage to be serialized and sent
qosQuality of Service for delivering this message
onPubAckcallback when the publish "completes" (see below)
Returns
true if the message was successfully queued for publication, false if there was an error
  • For QoS 0, completes as soon as the packet is sent.
  • For QoS 1, completes when PUBACK is received.
  • QoS 2 is not supported by AWS IoT.

◆ PublishGetNamedShadow()

bool Aws::Iotshadow::IotShadowClient::PublishGetNamedShadow ( const Aws::Iotshadow::GetNamedShadowRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnPublishComplete onPubAck 
)

Gets a named shadow for an AWS IoT thing.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#get-pub-sub-topic

Publish a GetNamedShadow message. If the device is offline, the PUBLISH packet will be sent once the connection resumes.

Parameters
requestMessage to be serialized and sent
qosQuality of Service for delivering this message
onPubAckcallback when the publish "completes" (see below)
Returns
true if the message was successfully queued for publication, false if there was an error
  • For QoS 0, completes as soon as the packet is sent.
  • For QoS 1, completes when PUBACK is received.
  • QoS 2 is not supported by AWS IoT.

◆ PublishGetShadow()

bool Aws::Iotshadow::IotShadowClient::PublishGetShadow ( const Aws::Iotshadow::GetShadowRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnPublishComplete onPubAck 
)

Gets the (classic) shadow for an AWS IoT thing.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#get-pub-sub-topic

Publish a GetShadow message. If the device is offline, the PUBLISH packet will be sent once the connection resumes.

Parameters
requestMessage to be serialized and sent
qosQuality of Service for delivering this message
onPubAckcallback when the publish "completes" (see below)
Returns
true if the message was successfully queued for publication, false if there was an error
  • For QoS 0, completes as soon as the packet is sent.
  • For QoS 1, completes when PUBACK is received.
  • QoS 2 is not supported by AWS IoT.

◆ PublishUpdateNamedShadow()

bool Aws::Iotshadow::IotShadowClient::PublishUpdateNamedShadow ( const Aws::Iotshadow::UpdateNamedShadowRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnPublishComplete onPubAck 
)

Update a named shadow for a device.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#update-pub-sub-topic

Publish a UpdateNamedShadow message. If the device is offline, the PUBLISH packet will be sent once the connection resumes.

Parameters
requestMessage to be serialized and sent
qosQuality of Service for delivering this message
onPubAckcallback when the publish "completes" (see below)
Returns
true if the message was successfully queued for publication, false if there was an error
  • For QoS 0, completes as soon as the packet is sent.
  • For QoS 1, completes when PUBACK is received.
  • QoS 2 is not supported by AWS IoT.

◆ PublishUpdateShadow()

bool Aws::Iotshadow::IotShadowClient::PublishUpdateShadow ( const Aws::Iotshadow::UpdateShadowRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnPublishComplete onPubAck 
)

Update a device's (classic) shadow.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#update-pub-sub-topic

Publish a UpdateShadow message. If the device is offline, the PUBLISH packet will be sent once the connection resumes.

Parameters
requestMessage to be serialized and sent
qosQuality of Service for delivering this message
onPubAckcallback when the publish "completes" (see below)
Returns
true if the message was successfully queued for publication, false if there was an error
  • For QoS 0, completes as soon as the packet is sent.
  • For QoS 1, completes when PUBACK is received.
  • QoS 2 is not supported by AWS IoT.

◆ SubscribeToDeleteNamedShadowAccepted()

bool Aws::Iotshadow::IotShadowClient::SubscribeToDeleteNamedShadowAccepted ( const Aws::Iotshadow::DeleteNamedShadowSubscriptionRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnSubscribeToDeleteNamedShadowAcceptedResponse handler,
const OnSubscribeComplete onSubAck 
)

Subscribes to the accepted topic for the DeleteNamedShadow operation.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#delete-accepted-pub-sub-topic

Subscribe to DeleteNamedShadowAccepted messages

Once subscribed, handler is invoked each time a message matching the topic is received. It is possible for such messages to arrive before the SUBACK is received.

Parameters
requestSubscription request configuration
qosMaximum requested QoS that server may use when sending messages to the client. The server may grant a lower QoS in the SUBACK
handlercallback function to invoke with messages received on the subscription topic
onSubAckcallback function invoked on receipt of the SUBACK from the server
Returns
true if the subscribe was successfully queued, false if there was an error doing so

◆ SubscribeToDeleteNamedShadowRejected()

bool Aws::Iotshadow::IotShadowClient::SubscribeToDeleteNamedShadowRejected ( const Aws::Iotshadow::DeleteNamedShadowSubscriptionRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnSubscribeToDeleteNamedShadowRejectedResponse handler,
const OnSubscribeComplete onSubAck 
)

Subscribes to the rejected topic for the DeleteNamedShadow operation.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#delete-rejected-pub-sub-topic

Subscribe to DeleteNamedShadowRejected messages

Once subscribed, handler is invoked each time a message matching the topic is received. It is possible for such messages to arrive before the SUBACK is received.

Parameters
requestSubscription request configuration
qosMaximum requested QoS that server may use when sending messages to the client. The server may grant a lower QoS in the SUBACK
handlercallback function to invoke with messages received on the subscription topic
onSubAckcallback function invoked on receipt of the SUBACK from the server
Returns
true if the subscribe was successfully queued, false if there was an error doing so

◆ SubscribeToDeleteShadowAccepted()

bool Aws::Iotshadow::IotShadowClient::SubscribeToDeleteShadowAccepted ( const Aws::Iotshadow::DeleteShadowSubscriptionRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnSubscribeToDeleteShadowAcceptedResponse handler,
const OnSubscribeComplete onSubAck 
)

Subscribes to the accepted topic for the DeleteShadow operation

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#delete-accepted-pub-sub-topic

Subscribe to DeleteShadowAccepted messages

Once subscribed, handler is invoked each time a message matching the topic is received. It is possible for such messages to arrive before the SUBACK is received.

Parameters
requestSubscription request configuration
qosMaximum requested QoS that server may use when sending messages to the client. The server may grant a lower QoS in the SUBACK
handlercallback function to invoke with messages received on the subscription topic
onSubAckcallback function invoked on receipt of the SUBACK from the server
Returns
true if the subscribe was successfully queued, false if there was an error doing so

◆ SubscribeToDeleteShadowRejected()

bool Aws::Iotshadow::IotShadowClient::SubscribeToDeleteShadowRejected ( const Aws::Iotshadow::DeleteShadowSubscriptionRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnSubscribeToDeleteShadowRejectedResponse handler,
const OnSubscribeComplete onSubAck 
)

Subscribes to the rejected topic for the DeleteShadow operation

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#delete-rejected-pub-sub-topic

Subscribe to DeleteShadowRejected messages

Once subscribed, handler is invoked each time a message matching the topic is received. It is possible for such messages to arrive before the SUBACK is received.

Parameters
requestSubscription request configuration
qosMaximum requested QoS that server may use when sending messages to the client. The server may grant a lower QoS in the SUBACK
handlercallback function to invoke with messages received on the subscription topic
onSubAckcallback function invoked on receipt of the SUBACK from the server
Returns
true if the subscribe was successfully queued, false if there was an error doing so

◆ SubscribeToGetNamedShadowAccepted()

bool Aws::Iotshadow::IotShadowClient::SubscribeToGetNamedShadowAccepted ( const Aws::Iotshadow::GetNamedShadowSubscriptionRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnSubscribeToGetNamedShadowAcceptedResponse handler,
const OnSubscribeComplete onSubAck 
)

Subscribes to the accepted topic for the GetNamedShadow operation.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#get-accepted-pub-sub-topic

Subscribe to GetNamedShadowAccepted messages

Once subscribed, handler is invoked each time a message matching the topic is received. It is possible for such messages to arrive before the SUBACK is received.

Parameters
requestSubscription request configuration
qosMaximum requested QoS that server may use when sending messages to the client. The server may grant a lower QoS in the SUBACK
handlercallback function to invoke with messages received on the subscription topic
onSubAckcallback function invoked on receipt of the SUBACK from the server
Returns
true if the subscribe was successfully queued, false if there was an error doing so

◆ SubscribeToGetNamedShadowRejected()

bool Aws::Iotshadow::IotShadowClient::SubscribeToGetNamedShadowRejected ( const Aws::Iotshadow::GetNamedShadowSubscriptionRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnSubscribeToGetNamedShadowRejectedResponse handler,
const OnSubscribeComplete onSubAck 
)

Subscribes to the rejected topic for the GetNamedShadow operation.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#get-rejected-pub-sub-topic

Subscribe to GetNamedShadowRejected messages

Once subscribed, handler is invoked each time a message matching the topic is received. It is possible for such messages to arrive before the SUBACK is received.

Parameters
requestSubscription request configuration
qosMaximum requested QoS that server may use when sending messages to the client. The server may grant a lower QoS in the SUBACK
handlercallback function to invoke with messages received on the subscription topic
onSubAckcallback function invoked on receipt of the SUBACK from the server
Returns
true if the subscribe was successfully queued, false if there was an error doing so

◆ SubscribeToGetShadowAccepted()

bool Aws::Iotshadow::IotShadowClient::SubscribeToGetShadowAccepted ( const Aws::Iotshadow::GetShadowSubscriptionRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnSubscribeToGetShadowAcceptedResponse handler,
const OnSubscribeComplete onSubAck 
)

Subscribes to the accepted topic for the GetShadow operation.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#get-accepted-pub-sub-topic

Subscribe to GetShadowAccepted messages

Once subscribed, handler is invoked each time a message matching the topic is received. It is possible for such messages to arrive before the SUBACK is received.

Parameters
requestSubscription request configuration
qosMaximum requested QoS that server may use when sending messages to the client. The server may grant a lower QoS in the SUBACK
handlercallback function to invoke with messages received on the subscription topic
onSubAckcallback function invoked on receipt of the SUBACK from the server
Returns
true if the subscribe was successfully queued, false if there was an error doing so

◆ SubscribeToGetShadowRejected()

bool Aws::Iotshadow::IotShadowClient::SubscribeToGetShadowRejected ( const Aws::Iotshadow::GetShadowSubscriptionRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnSubscribeToGetShadowRejectedResponse handler,
const OnSubscribeComplete onSubAck 
)

Subscribes to the rejected topic for the GetShadow operation.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#get-rejected-pub-sub-topic

Subscribe to GetShadowRejected messages

Once subscribed, handler is invoked each time a message matching the topic is received. It is possible for such messages to arrive before the SUBACK is received.

Parameters
requestSubscription request configuration
qosMaximum requested QoS that server may use when sending messages to the client. The server may grant a lower QoS in the SUBACK
handlercallback function to invoke with messages received on the subscription topic
onSubAckcallback function invoked on receipt of the SUBACK from the server
Returns
true if the subscribe was successfully queued, false if there was an error doing so

◆ SubscribeToNamedShadowDeltaUpdatedEvents()

bool Aws::Iotshadow::IotShadowClient::SubscribeToNamedShadowDeltaUpdatedEvents ( const Aws::Iotshadow::NamedShadowDeltaUpdatedSubscriptionRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnSubscribeToNamedShadowDeltaUpdatedEventsResponse handler,
const OnSubscribeComplete onSubAck 
)

Subscribe to NamedShadowDelta events for a named shadow of an AWS IoT thing.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#update-delta-pub-sub-topic

Subscribe to NamedShadowDeltaUpdatedEvents messages

Once subscribed, handler is invoked each time a message matching the topic is received. It is possible for such messages to arrive before the SUBACK is received.

Parameters
requestSubscription request configuration
qosMaximum requested QoS that server may use when sending messages to the client. The server may grant a lower QoS in the SUBACK
handlercallback function to invoke with messages received on the subscription topic
onSubAckcallback function invoked on receipt of the SUBACK from the server
Returns
true if the subscribe was successfully queued, false if there was an error doing so

◆ SubscribeToNamedShadowUpdatedEvents()

bool Aws::Iotshadow::IotShadowClient::SubscribeToNamedShadowUpdatedEvents ( const Aws::Iotshadow::NamedShadowUpdatedSubscriptionRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnSubscribeToNamedShadowUpdatedEventsResponse handler,
const OnSubscribeComplete onSubAck 
)

Subscribe to ShadowUpdated events for a named shadow of an AWS IoT thing.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#update-documents-pub-sub-topic

Subscribe to NamedShadowUpdatedEvents messages

Once subscribed, handler is invoked each time a message matching the topic is received. It is possible for such messages to arrive before the SUBACK is received.

Parameters
requestSubscription request configuration
qosMaximum requested QoS that server may use when sending messages to the client. The server may grant a lower QoS in the SUBACK
handlercallback function to invoke with messages received on the subscription topic
onSubAckcallback function invoked on receipt of the SUBACK from the server
Returns
true if the subscribe was successfully queued, false if there was an error doing so

◆ SubscribeToShadowDeltaUpdatedEvents()

bool Aws::Iotshadow::IotShadowClient::SubscribeToShadowDeltaUpdatedEvents ( const Aws::Iotshadow::ShadowDeltaUpdatedSubscriptionRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnSubscribeToShadowDeltaUpdatedEventsResponse handler,
const OnSubscribeComplete onSubAck 
)

Subscribe to ShadowDelta events for the (classic) shadow of an AWS IoT thing.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#update-delta-pub-sub-topic

Subscribe to ShadowDeltaUpdatedEvents messages

Once subscribed, handler is invoked each time a message matching the topic is received. It is possible for such messages to arrive before the SUBACK is received.

Parameters
requestSubscription request configuration
qosMaximum requested QoS that server may use when sending messages to the client. The server may grant a lower QoS in the SUBACK
handlercallback function to invoke with messages received on the subscription topic
onSubAckcallback function invoked on receipt of the SUBACK from the server
Returns
true if the subscribe was successfully queued, false if there was an error doing so

◆ SubscribeToShadowUpdatedEvents()

bool Aws::Iotshadow::IotShadowClient::SubscribeToShadowUpdatedEvents ( const Aws::Iotshadow::ShadowUpdatedSubscriptionRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnSubscribeToShadowUpdatedEventsResponse handler,
const OnSubscribeComplete onSubAck 
)

Subscribe to ShadowUpdated events for the (classic) shadow of an AWS IoT thing.

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#update-documents-pub-sub-topic

Subscribe to ShadowUpdatedEvents messages

Once subscribed, handler is invoked each time a message matching the topic is received. It is possible for such messages to arrive before the SUBACK is received.

Parameters
requestSubscription request configuration
qosMaximum requested QoS that server may use when sending messages to the client. The server may grant a lower QoS in the SUBACK
handlercallback function to invoke with messages received on the subscription topic
onSubAckcallback function invoked on receipt of the SUBACK from the server
Returns
true if the subscribe was successfully queued, false if there was an error doing so

◆ SubscribeToUpdateNamedShadowAccepted()

bool Aws::Iotshadow::IotShadowClient::SubscribeToUpdateNamedShadowAccepted ( const Aws::Iotshadow::UpdateNamedShadowSubscriptionRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnSubscribeToUpdateNamedShadowAcceptedResponse handler,
const OnSubscribeComplete onSubAck 
)

Subscribes to the accepted topic for the UpdateNamedShadow operation

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#update-accepted-pub-sub-topic

Subscribe to UpdateNamedShadowAccepted messages

Once subscribed, handler is invoked each time a message matching the topic is received. It is possible for such messages to arrive before the SUBACK is received.

Parameters
requestSubscription request configuration
qosMaximum requested QoS that server may use when sending messages to the client. The server may grant a lower QoS in the SUBACK
handlercallback function to invoke with messages received on the subscription topic
onSubAckcallback function invoked on receipt of the SUBACK from the server
Returns
true if the subscribe was successfully queued, false if there was an error doing so

◆ SubscribeToUpdateNamedShadowRejected()

bool Aws::Iotshadow::IotShadowClient::SubscribeToUpdateNamedShadowRejected ( const Aws::Iotshadow::UpdateNamedShadowSubscriptionRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnSubscribeToUpdateNamedShadowRejectedResponse handler,
const OnSubscribeComplete onSubAck 
)

Subscribes to the rejected topic for the UpdateNamedShadow operation

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#update-rejected-pub-sub-topic

Subscribe to UpdateNamedShadowRejected messages

Once subscribed, handler is invoked each time a message matching the topic is received. It is possible for such messages to arrive before the SUBACK is received.

Parameters
requestSubscription request configuration
qosMaximum requested QoS that server may use when sending messages to the client. The server may grant a lower QoS in the SUBACK
handlercallback function to invoke with messages received on the subscription topic
onSubAckcallback function invoked on receipt of the SUBACK from the server
Returns
true if the subscribe was successfully queued, false if there was an error doing so

◆ SubscribeToUpdateShadowAccepted()

bool Aws::Iotshadow::IotShadowClient::SubscribeToUpdateShadowAccepted ( const Aws::Iotshadow::UpdateShadowSubscriptionRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnSubscribeToUpdateShadowAcceptedResponse handler,
const OnSubscribeComplete onSubAck 
)

Subscribes to the accepted topic for the UpdateShadow operation

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#update-accepted-pub-sub-topic

Subscribe to UpdateShadowAccepted messages

Once subscribed, handler is invoked each time a message matching the topic is received. It is possible for such messages to arrive before the SUBACK is received.

Parameters
requestSubscription request configuration
qosMaximum requested QoS that server may use when sending messages to the client. The server may grant a lower QoS in the SUBACK
handlercallback function to invoke with messages received on the subscription topic
onSubAckcallback function invoked on receipt of the SUBACK from the server
Returns
true if the subscribe was successfully queued, false if there was an error doing so

◆ SubscribeToUpdateShadowRejected()

bool Aws::Iotshadow::IotShadowClient::SubscribeToUpdateShadowRejected ( const Aws::Iotshadow::UpdateShadowSubscriptionRequest request,
Aws::Crt::Mqtt::QOS  qos,
const OnSubscribeToUpdateShadowRejectedResponse handler,
const OnSubscribeComplete onSubAck 
)

Subscribes to the rejected topic for the UpdateShadow operation

https://docs.aws.amazon.com/iot/latest/developerguide/device-shadow-mqtt.html#update-rejected-pub-sub-topic

Subscribe to UpdateShadowRejected messages

Once subscribed, handler is invoked each time a message matching the topic is received. It is possible for such messages to arrive before the SUBACK is received.

Parameters
requestSubscription request configuration
qosMaximum requested QoS that server may use when sending messages to the client. The server may grant a lower QoS in the SUBACK
handlercallback function to invoke with messages received on the subscription topic
onSubAckcallback function invoked on receipt of the SUBACK from the server
Returns
true if the subscribe was successfully queued, false if there was an error doing so

The documentation for this class was generated from the following files: