aws_sdk_iotdataplane/client/
delete_connection.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2impl super::Client {
3    /// Constructs a fluent builder for the [`DeleteConnection`](crate::operation::delete_connection::builders::DeleteConnectionFluentBuilder) operation.
4    ///
5    /// - The fluent builder is configurable:
6    ///   - [`client_id(impl Into<String>)`](crate::operation::delete_connection::builders::DeleteConnectionFluentBuilder::client_id) / [`set_client_id(Option<String>)`](crate::operation::delete_connection::builders::DeleteConnectionFluentBuilder::set_client_id):<br>required: **true**<br><p>The unique identifier of the MQTT client to disconnect. The client ID can't start with a dollar sign ($).</p><br>
7    ///   - [`clean_session(bool)`](crate::operation::delete_connection::builders::DeleteConnectionFluentBuilder::clean_session) / [`set_clean_session(Option<bool>)`](crate::operation::delete_connection::builders::DeleteConnectionFluentBuilder::set_clean_session):<br>required: **false**<br><p>Specifies whether to remove the client's session state when disconnecting. Set to <code>TRUE</code> to delete all session information, including subscriptions and queued messages. Set to <code>FALSE</code> to preserve the session state. By default, this is set to <code>FALSE</code> (preserves the session state).</p><br>
8    ///   - [`prevent_will_message(bool)`](crate::operation::delete_connection::builders::DeleteConnectionFluentBuilder::prevent_will_message) / [`set_prevent_will_message(Option<bool>)`](crate::operation::delete_connection::builders::DeleteConnectionFluentBuilder::set_prevent_will_message):<br>required: **false**<br><p>Controls if Amazon Web Services IoT Core publishes the client's Last Will and Testament (LWT) message upon disconnection. Set to <code>TRUE</code> to prevent publishing the LWT message. Set to <code>FALSE</code> to allow publishing. By default, this is set to <code>FALSE</code> (allows publishing the LWT message).</p><br>
9    /// - On success, responds with [`DeleteConnectionOutput`](crate::operation::delete_connection::DeleteConnectionOutput)
10    /// - On failure, responds with [`SdkError<DeleteConnectionError>`](crate::operation::delete_connection::DeleteConnectionError)
11    pub fn delete_connection(&self) -> crate::operation::delete_connection::builders::DeleteConnectionFluentBuilder {
12        crate::operation::delete_connection::builders::DeleteConnectionFluentBuilder::new(self.handle.clone())
13    }
14}