Skip to main content

aws_sdk_ses/operation/update_configuration_set_sending_enabled/
_update_configuration_set_sending_enabled_input.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2
3/// <p>Represents a request to enable or disable the email sending capabilities for a specific configuration set.</p>
4#[non_exhaustive]
5#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
6pub struct UpdateConfigurationSetSendingEnabledInput {
7    /// <p>The name of the configuration set to update.</p>
8    pub configuration_set_name: ::std::option::Option<::std::string::String>,
9    /// <p>Describes whether email sending is enabled or disabled for the configuration set.</p>
10    pub enabled: ::std::option::Option<bool>,
11}
12impl UpdateConfigurationSetSendingEnabledInput {
13    /// <p>The name of the configuration set to update.</p>
14    pub fn configuration_set_name(&self) -> ::std::option::Option<&str> {
15        self.configuration_set_name.as_deref()
16    }
17    /// <p>Describes whether email sending is enabled or disabled for the configuration set.</p>
18    pub fn enabled(&self) -> ::std::option::Option<bool> {
19        self.enabled
20    }
21}
22impl UpdateConfigurationSetSendingEnabledInput {
23    /// Creates a new builder-style object to manufacture [`UpdateConfigurationSetSendingEnabledInput`](crate::operation::update_configuration_set_sending_enabled::UpdateConfigurationSetSendingEnabledInput).
24    pub fn builder() -> crate::operation::update_configuration_set_sending_enabled::builders::UpdateConfigurationSetSendingEnabledInputBuilder {
25        crate::operation::update_configuration_set_sending_enabled::builders::UpdateConfigurationSetSendingEnabledInputBuilder::default()
26    }
27}
28
29/// A builder for [`UpdateConfigurationSetSendingEnabledInput`](crate::operation::update_configuration_set_sending_enabled::UpdateConfigurationSetSendingEnabledInput).
30#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
31#[non_exhaustive]
32pub struct UpdateConfigurationSetSendingEnabledInputBuilder {
33    pub(crate) configuration_set_name: ::std::option::Option<::std::string::String>,
34    pub(crate) enabled: ::std::option::Option<bool>,
35}
36impl UpdateConfigurationSetSendingEnabledInputBuilder {
37    /// <p>The name of the configuration set to update.</p>
38    /// This field is required.
39    pub fn configuration_set_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
40        self.configuration_set_name = ::std::option::Option::Some(input.into());
41        self
42    }
43    /// <p>The name of the configuration set to update.</p>
44    pub fn set_configuration_set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
45        self.configuration_set_name = input;
46        self
47    }
48    /// <p>The name of the configuration set to update.</p>
49    pub fn get_configuration_set_name(&self) -> &::std::option::Option<::std::string::String> {
50        &self.configuration_set_name
51    }
52    /// <p>Describes whether email sending is enabled or disabled for the configuration set.</p>
53    /// This field is required.
54    pub fn enabled(mut self, input: bool) -> Self {
55        self.enabled = ::std::option::Option::Some(input);
56        self
57    }
58    /// <p>Describes whether email sending is enabled or disabled for the configuration set.</p>
59    pub fn set_enabled(mut self, input: ::std::option::Option<bool>) -> Self {
60        self.enabled = input;
61        self
62    }
63    /// <p>Describes whether email sending is enabled or disabled for the configuration set.</p>
64    pub fn get_enabled(&self) -> &::std::option::Option<bool> {
65        &self.enabled
66    }
67    /// Consumes the builder and constructs a [`UpdateConfigurationSetSendingEnabledInput`](crate::operation::update_configuration_set_sending_enabled::UpdateConfigurationSetSendingEnabledInput).
68    pub fn build(
69        self,
70    ) -> ::std::result::Result<
71        crate::operation::update_configuration_set_sending_enabled::UpdateConfigurationSetSendingEnabledInput,
72        ::aws_smithy_types::error::operation::BuildError,
73    > {
74        ::std::result::Result::Ok(
75            crate::operation::update_configuration_set_sending_enabled::UpdateConfigurationSetSendingEnabledInput {
76                configuration_set_name: self.configuration_set_name,
77                enabled: self.enabled,
78            },
79        )
80    }
81}