aws-sdk-iotmanagedintegrations 1.42.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 StartDeviceDiscoveryOutput {
    /// <p>The id of the device discovery job request.</p>
    pub id: ::std::option::Option<::std::string::String>,
    /// <p>The timestamp value for the start time of the device discovery.</p>
    pub started_at: ::std::option::Option<::aws_smithy_types::DateTime>,
    _request_id: Option<String>,
}
impl StartDeviceDiscoveryOutput {
    /// <p>The id of the device discovery job request.</p>
    pub fn id(&self) -> ::std::option::Option<&str> {
        self.id.as_deref()
    }
    /// <p>The timestamp value for the start time of the device discovery.</p>
    pub fn started_at(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
        self.started_at.as_ref()
    }
}
impl ::aws_types::request_id::RequestId for StartDeviceDiscoveryOutput {
    fn request_id(&self) -> Option<&str> {
        self._request_id.as_deref()
    }
}
impl StartDeviceDiscoveryOutput {
    /// Creates a new builder-style object to manufacture [`StartDeviceDiscoveryOutput`](crate::operation::start_device_discovery::StartDeviceDiscoveryOutput).
    pub fn builder() -> crate::operation::start_device_discovery::builders::StartDeviceDiscoveryOutputBuilder {
        crate::operation::start_device_discovery::builders::StartDeviceDiscoveryOutputBuilder::default()
    }
}

/// A builder for [`StartDeviceDiscoveryOutput`](crate::operation::start_device_discovery::StartDeviceDiscoveryOutput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct StartDeviceDiscoveryOutputBuilder {
    pub(crate) id: ::std::option::Option<::std::string::String>,
    pub(crate) started_at: ::std::option::Option<::aws_smithy_types::DateTime>,
    _request_id: Option<String>,
}
impl StartDeviceDiscoveryOutputBuilder {
    /// <p>The id of the device discovery job request.</p>
    pub fn id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The id of the device discovery job request.</p>
    pub fn set_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.id = input;
        self
    }
    /// <p>The id of the device discovery job request.</p>
    pub fn get_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.id
    }
    /// <p>The timestamp value for the start time of the device discovery.</p>
    pub fn started_at(mut self, input: ::aws_smithy_types::DateTime) -> Self {
        self.started_at = ::std::option::Option::Some(input);
        self
    }
    /// <p>The timestamp value for the start time of the device discovery.</p>
    pub fn set_started_at(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
        self.started_at = input;
        self
    }
    /// <p>The timestamp value for the start time of the device discovery.</p>
    pub fn get_started_at(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
        &self.started_at
    }
    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
        self._request_id = Some(request_id.into());
        self
    }

    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
        self._request_id = request_id;
        self
    }
    /// Consumes the builder and constructs a [`StartDeviceDiscoveryOutput`](crate::operation::start_device_discovery::StartDeviceDiscoveryOutput).
    pub fn build(self) -> crate::operation::start_device_discovery::StartDeviceDiscoveryOutput {
        crate::operation::start_device_discovery::StartDeviceDiscoveryOutput {
            id: self.id,
            started_at: self.started_at,
            _request_id: self._request_id,
        }
    }
}