aws-sdk-iotmanagedintegrations 1.43.0

AWS SDK for Managed integrations for AWS IoT Device Management
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct UpdateAccountAssociationInput {
    /// <p>The unique identifier of the account association to update.</p>
    pub account_association_id: ::std::option::Option<::std::string::String>,
    /// <p>The new name to assign to the account association.</p>
    pub name: ::std::option::Option<::std::string::String>,
    /// <p>The new description to assign to the account association.</p>
    pub description: ::std::option::Option<::std::string::String>,
}
impl UpdateAccountAssociationInput {
    /// <p>The unique identifier of the account association to update.</p>
    pub fn account_association_id(&self) -> ::std::option::Option<&str> {
        self.account_association_id.as_deref()
    }
    /// <p>The new name to assign to the account association.</p>
    pub fn name(&self) -> ::std::option::Option<&str> {
        self.name.as_deref()
    }
    /// <p>The new description to assign to the account association.</p>
    pub fn description(&self) -> ::std::option::Option<&str> {
        self.description.as_deref()
    }
}
impl UpdateAccountAssociationInput {
    /// Creates a new builder-style object to manufacture [`UpdateAccountAssociationInput`](crate::operation::update_account_association::UpdateAccountAssociationInput).
    pub fn builder() -> crate::operation::update_account_association::builders::UpdateAccountAssociationInputBuilder {
        crate::operation::update_account_association::builders::UpdateAccountAssociationInputBuilder::default()
    }
}

/// A builder for [`UpdateAccountAssociationInput`](crate::operation::update_account_association::UpdateAccountAssociationInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct UpdateAccountAssociationInputBuilder {
    pub(crate) account_association_id: ::std::option::Option<::std::string::String>,
    pub(crate) name: ::std::option::Option<::std::string::String>,
    pub(crate) description: ::std::option::Option<::std::string::String>,
}
impl UpdateAccountAssociationInputBuilder {
    /// <p>The unique identifier of the account association to update.</p>
    /// This field is required.
    pub fn account_association_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.account_association_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The unique identifier of the account association to update.</p>
    pub fn set_account_association_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.account_association_id = input;
        self
    }
    /// <p>The unique identifier of the account association to update.</p>
    pub fn get_account_association_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.account_association_id
    }
    /// <p>The new name to assign to the account association.</p>
    pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The new name to assign to the account association.</p>
    pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.name = input;
        self
    }
    /// <p>The new name to assign to the account association.</p>
    pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.name
    }
    /// <p>The new description to assign to the account association.</p>
    pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.description = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The new description to assign to the account association.</p>
    pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.description = input;
        self
    }
    /// <p>The new description to assign to the account association.</p>
    pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
        &self.description
    }
    /// Consumes the builder and constructs a [`UpdateAccountAssociationInput`](crate::operation::update_account_association::UpdateAccountAssociationInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<
        crate::operation::update_account_association::UpdateAccountAssociationInput,
        ::aws_smithy_types::error::operation::BuildError,
    > {
        ::std::result::Result::Ok(crate::operation::update_account_association::UpdateAccountAssociationInput {
            account_association_id: self.account_association_id,
            name: self.name,
            description: self.description,
        })
    }
}