aws_sdk_ses/operation/send_custom_verification_email/
_send_custom_verification_email_input.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2
3/// <p>Represents a request to send a custom verification email to a specified recipient.</p>
4#[non_exhaustive]
5#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
6pub struct SendCustomVerificationEmailInput {
7    /// <p>The email address to verify.</p>
8    pub email_address: ::std::option::Option<::std::string::String>,
9    /// <p>The name of the custom verification email template to use when sending the verification email.</p>
10    pub template_name: ::std::option::Option<::std::string::String>,
11    /// <p>Name of a configuration set to use when sending the verification email.</p>
12    pub configuration_set_name: ::std::option::Option<::std::string::String>,
13}
14impl SendCustomVerificationEmailInput {
15    /// <p>The email address to verify.</p>
16    pub fn email_address(&self) -> ::std::option::Option<&str> {
17        self.email_address.as_deref()
18    }
19    /// <p>The name of the custom verification email template to use when sending the verification email.</p>
20    pub fn template_name(&self) -> ::std::option::Option<&str> {
21        self.template_name.as_deref()
22    }
23    /// <p>Name of a configuration set to use when sending the verification email.</p>
24    pub fn configuration_set_name(&self) -> ::std::option::Option<&str> {
25        self.configuration_set_name.as_deref()
26    }
27}
28impl SendCustomVerificationEmailInput {
29    /// Creates a new builder-style object to manufacture [`SendCustomVerificationEmailInput`](crate::operation::send_custom_verification_email::SendCustomVerificationEmailInput).
30    pub fn builder() -> crate::operation::send_custom_verification_email::builders::SendCustomVerificationEmailInputBuilder {
31        crate::operation::send_custom_verification_email::builders::SendCustomVerificationEmailInputBuilder::default()
32    }
33}
34
35/// A builder for [`SendCustomVerificationEmailInput`](crate::operation::send_custom_verification_email::SendCustomVerificationEmailInput).
36#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
37#[non_exhaustive]
38pub struct SendCustomVerificationEmailInputBuilder {
39    pub(crate) email_address: ::std::option::Option<::std::string::String>,
40    pub(crate) template_name: ::std::option::Option<::std::string::String>,
41    pub(crate) configuration_set_name: ::std::option::Option<::std::string::String>,
42}
43impl SendCustomVerificationEmailInputBuilder {
44    /// <p>The email address to verify.</p>
45    /// This field is required.
46    pub fn email_address(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
47        self.email_address = ::std::option::Option::Some(input.into());
48        self
49    }
50    /// <p>The email address to verify.</p>
51    pub fn set_email_address(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
52        self.email_address = input;
53        self
54    }
55    /// <p>The email address to verify.</p>
56    pub fn get_email_address(&self) -> &::std::option::Option<::std::string::String> {
57        &self.email_address
58    }
59    /// <p>The name of the custom verification email template to use when sending the verification email.</p>
60    /// This field is required.
61    pub fn template_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
62        self.template_name = ::std::option::Option::Some(input.into());
63        self
64    }
65    /// <p>The name of the custom verification email template to use when sending the verification email.</p>
66    pub fn set_template_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
67        self.template_name = input;
68        self
69    }
70    /// <p>The name of the custom verification email template to use when sending the verification email.</p>
71    pub fn get_template_name(&self) -> &::std::option::Option<::std::string::String> {
72        &self.template_name
73    }
74    /// <p>Name of a configuration set to use when sending the verification email.</p>
75    pub fn configuration_set_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
76        self.configuration_set_name = ::std::option::Option::Some(input.into());
77        self
78    }
79    /// <p>Name of a configuration set to use when sending the verification email.</p>
80    pub fn set_configuration_set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
81        self.configuration_set_name = input;
82        self
83    }
84    /// <p>Name of a configuration set to use when sending the verification email.</p>
85    pub fn get_configuration_set_name(&self) -> &::std::option::Option<::std::string::String> {
86        &self.configuration_set_name
87    }
88    /// Consumes the builder and constructs a [`SendCustomVerificationEmailInput`](crate::operation::send_custom_verification_email::SendCustomVerificationEmailInput).
89    pub fn build(
90        self,
91    ) -> ::std::result::Result<
92        crate::operation::send_custom_verification_email::SendCustomVerificationEmailInput,
93        ::aws_smithy_types::error::operation::BuildError,
94    > {
95        ::std::result::Result::Ok(crate::operation::send_custom_verification_email::SendCustomVerificationEmailInput {
96            email_address: self.email_address,
97            template_name: self.template_name,
98            configuration_set_name: self.configuration_set_name,
99        })
100    }
101}