aws-sdk-iotdeviceadvisor 1.93.0

AWS SDK for AWS IoT Core Device Advisor
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 GetEndpointInput {
    /// <p>The thing ARN of the device. This is an optional parameter.</p>
    pub thing_arn: ::std::option::Option<::std::string::String>,
    /// <p>The certificate ARN of the device. This is an optional parameter.</p>
    pub certificate_arn: ::std::option::Option<::std::string::String>,
    /// <p>The device role ARN of the device. This is an optional parameter.</p>
    pub device_role_arn: ::std::option::Option<::std::string::String>,
    /// <p>The authentication method used during the device connection.</p>
    pub authentication_method: ::std::option::Option<crate::types::AuthenticationMethod>,
}
impl GetEndpointInput {
    /// <p>The thing ARN of the device. This is an optional parameter.</p>
    pub fn thing_arn(&self) -> ::std::option::Option<&str> {
        self.thing_arn.as_deref()
    }
    /// <p>The certificate ARN of the device. This is an optional parameter.</p>
    pub fn certificate_arn(&self) -> ::std::option::Option<&str> {
        self.certificate_arn.as_deref()
    }
    /// <p>The device role ARN of the device. This is an optional parameter.</p>
    pub fn device_role_arn(&self) -> ::std::option::Option<&str> {
        self.device_role_arn.as_deref()
    }
    /// <p>The authentication method used during the device connection.</p>
    pub fn authentication_method(&self) -> ::std::option::Option<&crate::types::AuthenticationMethod> {
        self.authentication_method.as_ref()
    }
}
impl GetEndpointInput {
    /// Creates a new builder-style object to manufacture [`GetEndpointInput`](crate::operation::get_endpoint::GetEndpointInput).
    pub fn builder() -> crate::operation::get_endpoint::builders::GetEndpointInputBuilder {
        crate::operation::get_endpoint::builders::GetEndpointInputBuilder::default()
    }
}

/// A builder for [`GetEndpointInput`](crate::operation::get_endpoint::GetEndpointInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GetEndpointInputBuilder {
    pub(crate) thing_arn: ::std::option::Option<::std::string::String>,
    pub(crate) certificate_arn: ::std::option::Option<::std::string::String>,
    pub(crate) device_role_arn: ::std::option::Option<::std::string::String>,
    pub(crate) authentication_method: ::std::option::Option<crate::types::AuthenticationMethod>,
}
impl GetEndpointInputBuilder {
    /// <p>The thing ARN of the device. This is an optional parameter.</p>
    pub fn thing_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.thing_arn = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The thing ARN of the device. This is an optional parameter.</p>
    pub fn set_thing_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.thing_arn = input;
        self
    }
    /// <p>The thing ARN of the device. This is an optional parameter.</p>
    pub fn get_thing_arn(&self) -> &::std::option::Option<::std::string::String> {
        &self.thing_arn
    }
    /// <p>The certificate ARN of the device. This is an optional parameter.</p>
    pub fn certificate_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.certificate_arn = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The certificate ARN of the device. This is an optional parameter.</p>
    pub fn set_certificate_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.certificate_arn = input;
        self
    }
    /// <p>The certificate ARN of the device. This is an optional parameter.</p>
    pub fn get_certificate_arn(&self) -> &::std::option::Option<::std::string::String> {
        &self.certificate_arn
    }
    /// <p>The device role ARN of the device. This is an optional parameter.</p>
    pub fn device_role_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.device_role_arn = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The device role ARN of the device. This is an optional parameter.</p>
    pub fn set_device_role_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.device_role_arn = input;
        self
    }
    /// <p>The device role ARN of the device. This is an optional parameter.</p>
    pub fn get_device_role_arn(&self) -> &::std::option::Option<::std::string::String> {
        &self.device_role_arn
    }
    /// <p>The authentication method used during the device connection.</p>
    pub fn authentication_method(mut self, input: crate::types::AuthenticationMethod) -> Self {
        self.authentication_method = ::std::option::Option::Some(input);
        self
    }
    /// <p>The authentication method used during the device connection.</p>
    pub fn set_authentication_method(mut self, input: ::std::option::Option<crate::types::AuthenticationMethod>) -> Self {
        self.authentication_method = input;
        self
    }
    /// <p>The authentication method used during the device connection.</p>
    pub fn get_authentication_method(&self) -> &::std::option::Option<crate::types::AuthenticationMethod> {
        &self.authentication_method
    }
    /// Consumes the builder and constructs a [`GetEndpointInput`](crate::operation::get_endpoint::GetEndpointInput).
    pub fn build(self) -> ::std::result::Result<crate::operation::get_endpoint::GetEndpointInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::get_endpoint::GetEndpointInput {
            thing_arn: self.thing_arn,
            certificate_arn: self.certificate_arn,
            device_role_arn: self.device_role_arn,
            authentication_method: self.authentication_method,
        })
    }
}