aws_sdk_pinpointemail/types/_domain_isp_placement.rs
1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2
3/// <p>An object that contains inbox placement data for email sent from one of your email domains to a specific email provider.</p>
4#[non_exhaustive]
5#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
6pub struct DomainIspPlacement {
7 /// <p>The name of the email provider that the inbox placement data applies to.</p>
8 pub isp_name: ::std::option::Option<::std::string::String>,
9 /// <p>The total number of messages that were sent from the selected domain to the specified email provider that arrived in recipients' inboxes.</p>
10 pub inbox_raw_count: ::std::option::Option<i64>,
11 /// <p>The total number of messages that were sent from the selected domain to the specified email provider that arrived in recipients' spam or junk mail folders.</p>
12 pub spam_raw_count: ::std::option::Option<i64>,
13 /// <p>The percentage of messages that were sent from the selected domain to the specified email provider that arrived in recipients' inboxes.</p>
14 pub inbox_percentage: ::std::option::Option<f64>,
15 /// <p>The percentage of messages that were sent from the selected domain to the specified email provider that arrived in recipients' spam or junk mail folders.</p>
16 pub spam_percentage: ::std::option::Option<f64>,
17}
18impl DomainIspPlacement {
19 /// <p>The name of the email provider that the inbox placement data applies to.</p>
20 pub fn isp_name(&self) -> ::std::option::Option<&str> {
21 self.isp_name.as_deref()
22 }
23 /// <p>The total number of messages that were sent from the selected domain to the specified email provider that arrived in recipients' inboxes.</p>
24 pub fn inbox_raw_count(&self) -> ::std::option::Option<i64> {
25 self.inbox_raw_count
26 }
27 /// <p>The total number of messages that were sent from the selected domain to the specified email provider that arrived in recipients' spam or junk mail folders.</p>
28 pub fn spam_raw_count(&self) -> ::std::option::Option<i64> {
29 self.spam_raw_count
30 }
31 /// <p>The percentage of messages that were sent from the selected domain to the specified email provider that arrived in recipients' inboxes.</p>
32 pub fn inbox_percentage(&self) -> ::std::option::Option<f64> {
33 self.inbox_percentage
34 }
35 /// <p>The percentage of messages that were sent from the selected domain to the specified email provider that arrived in recipients' spam or junk mail folders.</p>
36 pub fn spam_percentage(&self) -> ::std::option::Option<f64> {
37 self.spam_percentage
38 }
39}
40impl DomainIspPlacement {
41 /// Creates a new builder-style object to manufacture [`DomainIspPlacement`](crate::types::DomainIspPlacement).
42 pub fn builder() -> crate::types::builders::DomainIspPlacementBuilder {
43 crate::types::builders::DomainIspPlacementBuilder::default()
44 }
45}
46
47/// A builder for [`DomainIspPlacement`](crate::types::DomainIspPlacement).
48#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
49#[non_exhaustive]
50pub struct DomainIspPlacementBuilder {
51 pub(crate) isp_name: ::std::option::Option<::std::string::String>,
52 pub(crate) inbox_raw_count: ::std::option::Option<i64>,
53 pub(crate) spam_raw_count: ::std::option::Option<i64>,
54 pub(crate) inbox_percentage: ::std::option::Option<f64>,
55 pub(crate) spam_percentage: ::std::option::Option<f64>,
56}
57impl DomainIspPlacementBuilder {
58 /// <p>The name of the email provider that the inbox placement data applies to.</p>
59 pub fn isp_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
60 self.isp_name = ::std::option::Option::Some(input.into());
61 self
62 }
63 /// <p>The name of the email provider that the inbox placement data applies to.</p>
64 pub fn set_isp_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
65 self.isp_name = input;
66 self
67 }
68 /// <p>The name of the email provider that the inbox placement data applies to.</p>
69 pub fn get_isp_name(&self) -> &::std::option::Option<::std::string::String> {
70 &self.isp_name
71 }
72 /// <p>The total number of messages that were sent from the selected domain to the specified email provider that arrived in recipients' inboxes.</p>
73 pub fn inbox_raw_count(mut self, input: i64) -> Self {
74 self.inbox_raw_count = ::std::option::Option::Some(input);
75 self
76 }
77 /// <p>The total number of messages that were sent from the selected domain to the specified email provider that arrived in recipients' inboxes.</p>
78 pub fn set_inbox_raw_count(mut self, input: ::std::option::Option<i64>) -> Self {
79 self.inbox_raw_count = input;
80 self
81 }
82 /// <p>The total number of messages that were sent from the selected domain to the specified email provider that arrived in recipients' inboxes.</p>
83 pub fn get_inbox_raw_count(&self) -> &::std::option::Option<i64> {
84 &self.inbox_raw_count
85 }
86 /// <p>The total number of messages that were sent from the selected domain to the specified email provider that arrived in recipients' spam or junk mail folders.</p>
87 pub fn spam_raw_count(mut self, input: i64) -> Self {
88 self.spam_raw_count = ::std::option::Option::Some(input);
89 self
90 }
91 /// <p>The total number of messages that were sent from the selected domain to the specified email provider that arrived in recipients' spam or junk mail folders.</p>
92 pub fn set_spam_raw_count(mut self, input: ::std::option::Option<i64>) -> Self {
93 self.spam_raw_count = input;
94 self
95 }
96 /// <p>The total number of messages that were sent from the selected domain to the specified email provider that arrived in recipients' spam or junk mail folders.</p>
97 pub fn get_spam_raw_count(&self) -> &::std::option::Option<i64> {
98 &self.spam_raw_count
99 }
100 /// <p>The percentage of messages that were sent from the selected domain to the specified email provider that arrived in recipients' inboxes.</p>
101 pub fn inbox_percentage(mut self, input: f64) -> Self {
102 self.inbox_percentage = ::std::option::Option::Some(input);
103 self
104 }
105 /// <p>The percentage of messages that were sent from the selected domain to the specified email provider that arrived in recipients' inboxes.</p>
106 pub fn set_inbox_percentage(mut self, input: ::std::option::Option<f64>) -> Self {
107 self.inbox_percentage = input;
108 self
109 }
110 /// <p>The percentage of messages that were sent from the selected domain to the specified email provider that arrived in recipients' inboxes.</p>
111 pub fn get_inbox_percentage(&self) -> &::std::option::Option<f64> {
112 &self.inbox_percentage
113 }
114 /// <p>The percentage of messages that were sent from the selected domain to the specified email provider that arrived in recipients' spam or junk mail folders.</p>
115 pub fn spam_percentage(mut self, input: f64) -> Self {
116 self.spam_percentage = ::std::option::Option::Some(input);
117 self
118 }
119 /// <p>The percentage of messages that were sent from the selected domain to the specified email provider that arrived in recipients' spam or junk mail folders.</p>
120 pub fn set_spam_percentage(mut self, input: ::std::option::Option<f64>) -> Self {
121 self.spam_percentage = input;
122 self
123 }
124 /// <p>The percentage of messages that were sent from the selected domain to the specified email provider that arrived in recipients' spam or junk mail folders.</p>
125 pub fn get_spam_percentage(&self) -> &::std::option::Option<f64> {
126 &self.spam_percentage
127 }
128 /// Consumes the builder and constructs a [`DomainIspPlacement`](crate::types::DomainIspPlacement).
129 pub fn build(self) -> crate::types::DomainIspPlacement {
130 crate::types::DomainIspPlacement {
131 isp_name: self.isp_name,
132 inbox_raw_count: self.inbox_raw_count,
133 spam_raw_count: self.spam_raw_count,
134 inbox_percentage: self.inbox_percentage,
135 spam_percentage: self.spam_percentage,
136 }
137 }
138}