aws-sdk-ssmquicksetup 1.75.0

AWS SDK for AWS Systems Manager QuickSetup
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)]
pub struct GetConfigurationManagerOutput {
    /// <p>The ARN of the configuration manager.</p>
    pub manager_arn: ::std::string::String,
    /// <p>The description of the configuration manager.</p>
    pub description: ::std::option::Option<::std::string::String>,
    /// <p>The name of the configuration manager.</p>
    pub name: ::std::option::Option<::std::string::String>,
    /// <p>The datetime stamp when the configuration manager was created.</p>
    pub created_at: ::std::option::Option<::aws_smithy_types::DateTime>,
    /// <p>The datetime stamp when the configuration manager was last updated.</p>
    pub last_modified_at: ::std::option::Option<::aws_smithy_types::DateTime>,
    /// <p>A summary of the state of the configuration manager. This includes deployment statuses, association statuses, drift statuses, health checks, and more.</p>
    pub status_summaries: ::std::option::Option<::std::vec::Vec<crate::types::StatusSummary>>,
    /// <p>The configuration definitions association with the configuration manager.</p>
    pub configuration_definitions: ::std::option::Option<::std::vec::Vec<crate::types::ConfigurationDefinition>>,
    /// <p>Key-value pairs of metadata to assign to the configuration manager.</p>
    pub tags: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
    _request_id: Option<String>,
}
impl GetConfigurationManagerOutput {
    /// <p>The ARN of the configuration manager.</p>
    pub fn manager_arn(&self) -> &str {
        use std::ops::Deref;
        self.manager_arn.deref()
    }
    /// <p>The description of the configuration manager.</p>
    pub fn description(&self) -> ::std::option::Option<&str> {
        self.description.as_deref()
    }
    /// <p>The name of the configuration manager.</p>
    pub fn name(&self) -> ::std::option::Option<&str> {
        self.name.as_deref()
    }
    /// <p>The datetime stamp when the configuration manager was created.</p>
    pub fn created_at(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
        self.created_at.as_ref()
    }
    /// <p>The datetime stamp when the configuration manager was last updated.</p>
    pub fn last_modified_at(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
        self.last_modified_at.as_ref()
    }
    /// <p>A summary of the state of the configuration manager. This includes deployment statuses, association statuses, drift statuses, health checks, and more.</p>
    ///
    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.status_summaries.is_none()`.
    pub fn status_summaries(&self) -> &[crate::types::StatusSummary] {
        self.status_summaries.as_deref().unwrap_or_default()
    }
    /// <p>The configuration definitions association with the configuration manager.</p>
    ///
    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.configuration_definitions.is_none()`.
    pub fn configuration_definitions(&self) -> &[crate::types::ConfigurationDefinition] {
        self.configuration_definitions.as_deref().unwrap_or_default()
    }
    /// <p>Key-value pairs of metadata to assign to the configuration manager.</p>
    pub fn tags(&self) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, ::std::string::String>> {
        self.tags.as_ref()
    }
}
impl ::std::fmt::Debug for GetConfigurationManagerOutput {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        let mut formatter = f.debug_struct("GetConfigurationManagerOutput");
        formatter.field("manager_arn", &self.manager_arn);
        formatter.field("description", &self.description);
        formatter.field("name", &self.name);
        formatter.field("created_at", &self.created_at);
        formatter.field("last_modified_at", &self.last_modified_at);
        formatter.field("status_summaries", &self.status_summaries);
        formatter.field("configuration_definitions", &self.configuration_definitions);
        formatter.field("tags", &"*** Sensitive Data Redacted ***");
        formatter.field("_request_id", &self._request_id);
        formatter.finish()
    }
}
impl ::aws_types::request_id::RequestId for GetConfigurationManagerOutput {
    fn request_id(&self) -> Option<&str> {
        self._request_id.as_deref()
    }
}
impl GetConfigurationManagerOutput {
    /// Creates a new builder-style object to manufacture [`GetConfigurationManagerOutput`](crate::operation::get_configuration_manager::GetConfigurationManagerOutput).
    pub fn builder() -> crate::operation::get_configuration_manager::builders::GetConfigurationManagerOutputBuilder {
        crate::operation::get_configuration_manager::builders::GetConfigurationManagerOutputBuilder::default()
    }
}

/// A builder for [`GetConfigurationManagerOutput`](crate::operation::get_configuration_manager::GetConfigurationManagerOutput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default)]
#[non_exhaustive]
pub struct GetConfigurationManagerOutputBuilder {
    pub(crate) manager_arn: ::std::option::Option<::std::string::String>,
    pub(crate) description: ::std::option::Option<::std::string::String>,
    pub(crate) name: ::std::option::Option<::std::string::String>,
    pub(crate) created_at: ::std::option::Option<::aws_smithy_types::DateTime>,
    pub(crate) last_modified_at: ::std::option::Option<::aws_smithy_types::DateTime>,
    pub(crate) status_summaries: ::std::option::Option<::std::vec::Vec<crate::types::StatusSummary>>,
    pub(crate) configuration_definitions: ::std::option::Option<::std::vec::Vec<crate::types::ConfigurationDefinition>>,
    pub(crate) tags: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
    _request_id: Option<String>,
}
impl GetConfigurationManagerOutputBuilder {
    /// <p>The ARN of the configuration manager.</p>
    /// This field is required.
    pub fn manager_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.manager_arn = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ARN of the configuration manager.</p>
    pub fn set_manager_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.manager_arn = input;
        self
    }
    /// <p>The ARN of the configuration manager.</p>
    pub fn get_manager_arn(&self) -> &::std::option::Option<::std::string::String> {
        &self.manager_arn
    }
    /// <p>The description of the configuration manager.</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 description of the configuration manager.</p>
    pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.description = input;
        self
    }
    /// <p>The description of the configuration manager.</p>
    pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
        &self.description
    }
    /// <p>The name of the configuration manager.</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 name of the configuration manager.</p>
    pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.name = input;
        self
    }
    /// <p>The name of the configuration manager.</p>
    pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.name
    }
    /// <p>The datetime stamp when the configuration manager was created.</p>
    pub fn created_at(mut self, input: ::aws_smithy_types::DateTime) -> Self {
        self.created_at = ::std::option::Option::Some(input);
        self
    }
    /// <p>The datetime stamp when the configuration manager was created.</p>
    pub fn set_created_at(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
        self.created_at = input;
        self
    }
    /// <p>The datetime stamp when the configuration manager was created.</p>
    pub fn get_created_at(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
        &self.created_at
    }
    /// <p>The datetime stamp when the configuration manager was last updated.</p>
    pub fn last_modified_at(mut self, input: ::aws_smithy_types::DateTime) -> Self {
        self.last_modified_at = ::std::option::Option::Some(input);
        self
    }
    /// <p>The datetime stamp when the configuration manager was last updated.</p>
    pub fn set_last_modified_at(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
        self.last_modified_at = input;
        self
    }
    /// <p>The datetime stamp when the configuration manager was last updated.</p>
    pub fn get_last_modified_at(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
        &self.last_modified_at
    }
    /// Appends an item to `status_summaries`.
    ///
    /// To override the contents of this collection use [`set_status_summaries`](Self::set_status_summaries).
    ///
    /// <p>A summary of the state of the configuration manager. This includes deployment statuses, association statuses, drift statuses, health checks, and more.</p>
    pub fn status_summaries(mut self, input: crate::types::StatusSummary) -> Self {
        let mut v = self.status_summaries.unwrap_or_default();
        v.push(input);
        self.status_summaries = ::std::option::Option::Some(v);
        self
    }
    /// <p>A summary of the state of the configuration manager. This includes deployment statuses, association statuses, drift statuses, health checks, and more.</p>
    pub fn set_status_summaries(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::StatusSummary>>) -> Self {
        self.status_summaries = input;
        self
    }
    /// <p>A summary of the state of the configuration manager. This includes deployment statuses, association statuses, drift statuses, health checks, and more.</p>
    pub fn get_status_summaries(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::StatusSummary>> {
        &self.status_summaries
    }
    /// Appends an item to `configuration_definitions`.
    ///
    /// To override the contents of this collection use [`set_configuration_definitions`](Self::set_configuration_definitions).
    ///
    /// <p>The configuration definitions association with the configuration manager.</p>
    pub fn configuration_definitions(mut self, input: crate::types::ConfigurationDefinition) -> Self {
        let mut v = self.configuration_definitions.unwrap_or_default();
        v.push(input);
        self.configuration_definitions = ::std::option::Option::Some(v);
        self
    }
    /// <p>The configuration definitions association with the configuration manager.</p>
    pub fn set_configuration_definitions(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::ConfigurationDefinition>>) -> Self {
        self.configuration_definitions = input;
        self
    }
    /// <p>The configuration definitions association with the configuration manager.</p>
    pub fn get_configuration_definitions(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::ConfigurationDefinition>> {
        &self.configuration_definitions
    }
    /// Adds a key-value pair to `tags`.
    ///
    /// To override the contents of this collection use [`set_tags`](Self::set_tags).
    ///
    /// <p>Key-value pairs of metadata to assign to the configuration manager.</p>
    pub fn tags(mut self, k: impl ::std::convert::Into<::std::string::String>, v: impl ::std::convert::Into<::std::string::String>) -> Self {
        let mut hash_map = self.tags.unwrap_or_default();
        hash_map.insert(k.into(), v.into());
        self.tags = ::std::option::Option::Some(hash_map);
        self
    }
    /// <p>Key-value pairs of metadata to assign to the configuration manager.</p>
    pub fn set_tags(mut self, input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>) -> Self {
        self.tags = input;
        self
    }
    /// <p>Key-value pairs of metadata to assign to the configuration manager.</p>
    pub fn get_tags(&self) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>> {
        &self.tags
    }
    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 [`GetConfigurationManagerOutput`](crate::operation::get_configuration_manager::GetConfigurationManagerOutput).
    /// This method will fail if any of the following fields are not set:
    /// - [`manager_arn`](crate::operation::get_configuration_manager::builders::GetConfigurationManagerOutputBuilder::manager_arn)
    pub fn build(
        self,
    ) -> ::std::result::Result<
        crate::operation::get_configuration_manager::GetConfigurationManagerOutput,
        ::aws_smithy_types::error::operation::BuildError,
    > {
        ::std::result::Result::Ok(crate::operation::get_configuration_manager::GetConfigurationManagerOutput {
            manager_arn: self.manager_arn.ok_or_else(|| {
                ::aws_smithy_types::error::operation::BuildError::missing_field(
                    "manager_arn",
                    "manager_arn was not specified but it is required when building GetConfigurationManagerOutput",
                )
            })?,
            description: self.description,
            name: self.name,
            created_at: self.created_at,
            last_modified_at: self.last_modified_at,
            status_summaries: self.status_summaries,
            configuration_definitions: self.configuration_definitions,
            tags: self.tags,
            _request_id: self._request_id,
        })
    }
}
impl ::std::fmt::Debug for GetConfigurationManagerOutputBuilder {
    fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
        let mut formatter = f.debug_struct("GetConfigurationManagerOutputBuilder");
        formatter.field("manager_arn", &self.manager_arn);
        formatter.field("description", &self.description);
        formatter.field("name", &self.name);
        formatter.field("created_at", &self.created_at);
        formatter.field("last_modified_at", &self.last_modified_at);
        formatter.field("status_summaries", &self.status_summaries);
        formatter.field("configuration_definitions", &self.configuration_definitions);
        formatter.field("tags", &"*** Sensitive Data Redacted ***");
        formatter.field("_request_id", &self._request_id);
        formatter.finish()
    }
}