1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.

/// <p>Describes the transit gateway multicast group resources.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct TransitGatewayMulticastGroup {
    /// <p>The IP address assigned to the transit gateway multicast group.</p>
    pub group_ip_address: ::std::option::Option<::std::string::String>,
    /// <p>The ID of the transit gateway attachment.</p>
    pub transit_gateway_attachment_id: ::std::option::Option<::std::string::String>,
    /// <p>The ID of the subnet.</p>
    pub subnet_id: ::std::option::Option<::std::string::String>,
    /// <p>The ID of the resource.</p>
    pub resource_id: ::std::option::Option<::std::string::String>,
    /// <p>The type of resource, for example a VPC attachment.</p>
    pub resource_type: ::std::option::Option<crate::types::TransitGatewayAttachmentResourceType>,
    /// <p> The ID of the Amazon Web Services account that owns the transit gateway multicast domain group resource.</p>
    pub resource_owner_id: ::std::option::Option<::std::string::String>,
    /// <p>The ID of the transit gateway attachment.</p>
    pub network_interface_id: ::std::option::Option<::std::string::String>,
    /// <p>Indicates that the resource is a transit gateway multicast group member.</p>
    pub group_member: ::std::option::Option<bool>,
    /// <p>Indicates that the resource is a transit gateway multicast group member.</p>
    pub group_source: ::std::option::Option<bool>,
    /// <p>The member type (for example, <code>static</code>).</p>
    pub member_type: ::std::option::Option<crate::types::MembershipType>,
    /// <p>The source type.</p>
    pub source_type: ::std::option::Option<crate::types::MembershipType>,
}
impl TransitGatewayMulticastGroup {
    /// <p>The IP address assigned to the transit gateway multicast group.</p>
    pub fn group_ip_address(&self) -> ::std::option::Option<&str> {
        self.group_ip_address.as_deref()
    }
    /// <p>The ID of the transit gateway attachment.</p>
    pub fn transit_gateway_attachment_id(&self) -> ::std::option::Option<&str> {
        self.transit_gateway_attachment_id.as_deref()
    }
    /// <p>The ID of the subnet.</p>
    pub fn subnet_id(&self) -> ::std::option::Option<&str> {
        self.subnet_id.as_deref()
    }
    /// <p>The ID of the resource.</p>
    pub fn resource_id(&self) -> ::std::option::Option<&str> {
        self.resource_id.as_deref()
    }
    /// <p>The type of resource, for example a VPC attachment.</p>
    pub fn resource_type(&self) -> ::std::option::Option<&crate::types::TransitGatewayAttachmentResourceType> {
        self.resource_type.as_ref()
    }
    /// <p> The ID of the Amazon Web Services account that owns the transit gateway multicast domain group resource.</p>
    pub fn resource_owner_id(&self) -> ::std::option::Option<&str> {
        self.resource_owner_id.as_deref()
    }
    /// <p>The ID of the transit gateway attachment.</p>
    pub fn network_interface_id(&self) -> ::std::option::Option<&str> {
        self.network_interface_id.as_deref()
    }
    /// <p>Indicates that the resource is a transit gateway multicast group member.</p>
    pub fn group_member(&self) -> ::std::option::Option<bool> {
        self.group_member
    }
    /// <p>Indicates that the resource is a transit gateway multicast group member.</p>
    pub fn group_source(&self) -> ::std::option::Option<bool> {
        self.group_source
    }
    /// <p>The member type (for example, <code>static</code>).</p>
    pub fn member_type(&self) -> ::std::option::Option<&crate::types::MembershipType> {
        self.member_type.as_ref()
    }
    /// <p>The source type.</p>
    pub fn source_type(&self) -> ::std::option::Option<&crate::types::MembershipType> {
        self.source_type.as_ref()
    }
}
impl TransitGatewayMulticastGroup {
    /// Creates a new builder-style object to manufacture [`TransitGatewayMulticastGroup`](crate::types::TransitGatewayMulticastGroup).
    pub fn builder() -> crate::types::builders::TransitGatewayMulticastGroupBuilder {
        crate::types::builders::TransitGatewayMulticastGroupBuilder::default()
    }
}

/// A builder for [`TransitGatewayMulticastGroup`](crate::types::TransitGatewayMulticastGroup).
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct TransitGatewayMulticastGroupBuilder {
    pub(crate) group_ip_address: ::std::option::Option<::std::string::String>,
    pub(crate) transit_gateway_attachment_id: ::std::option::Option<::std::string::String>,
    pub(crate) subnet_id: ::std::option::Option<::std::string::String>,
    pub(crate) resource_id: ::std::option::Option<::std::string::String>,
    pub(crate) resource_type: ::std::option::Option<crate::types::TransitGatewayAttachmentResourceType>,
    pub(crate) resource_owner_id: ::std::option::Option<::std::string::String>,
    pub(crate) network_interface_id: ::std::option::Option<::std::string::String>,
    pub(crate) group_member: ::std::option::Option<bool>,
    pub(crate) group_source: ::std::option::Option<bool>,
    pub(crate) member_type: ::std::option::Option<crate::types::MembershipType>,
    pub(crate) source_type: ::std::option::Option<crate::types::MembershipType>,
}
impl TransitGatewayMulticastGroupBuilder {
    /// <p>The IP address assigned to the transit gateway multicast group.</p>
    pub fn group_ip_address(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.group_ip_address = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The IP address assigned to the transit gateway multicast group.</p>
    pub fn set_group_ip_address(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.group_ip_address = input;
        self
    }
    /// <p>The IP address assigned to the transit gateway multicast group.</p>
    pub fn get_group_ip_address(&self) -> &::std::option::Option<::std::string::String> {
        &self.group_ip_address
    }
    /// <p>The ID of the transit gateway attachment.</p>
    pub fn transit_gateway_attachment_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.transit_gateway_attachment_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ID of the transit gateway attachment.</p>
    pub fn set_transit_gateway_attachment_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.transit_gateway_attachment_id = input;
        self
    }
    /// <p>The ID of the transit gateway attachment.</p>
    pub fn get_transit_gateway_attachment_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.transit_gateway_attachment_id
    }
    /// <p>The ID of the subnet.</p>
    pub fn subnet_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.subnet_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ID of the subnet.</p>
    pub fn set_subnet_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.subnet_id = input;
        self
    }
    /// <p>The ID of the subnet.</p>
    pub fn get_subnet_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.subnet_id
    }
    /// <p>The ID of the resource.</p>
    pub fn resource_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.resource_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ID of the resource.</p>
    pub fn set_resource_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.resource_id = input;
        self
    }
    /// <p>The ID of the resource.</p>
    pub fn get_resource_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.resource_id
    }
    /// <p>The type of resource, for example a VPC attachment.</p>
    pub fn resource_type(mut self, input: crate::types::TransitGatewayAttachmentResourceType) -> Self {
        self.resource_type = ::std::option::Option::Some(input);
        self
    }
    /// <p>The type of resource, for example a VPC attachment.</p>
    pub fn set_resource_type(mut self, input: ::std::option::Option<crate::types::TransitGatewayAttachmentResourceType>) -> Self {
        self.resource_type = input;
        self
    }
    /// <p>The type of resource, for example a VPC attachment.</p>
    pub fn get_resource_type(&self) -> &::std::option::Option<crate::types::TransitGatewayAttachmentResourceType> {
        &self.resource_type
    }
    /// <p> The ID of the Amazon Web Services account that owns the transit gateway multicast domain group resource.</p>
    pub fn resource_owner_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.resource_owner_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p> The ID of the Amazon Web Services account that owns the transit gateway multicast domain group resource.</p>
    pub fn set_resource_owner_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.resource_owner_id = input;
        self
    }
    /// <p> The ID of the Amazon Web Services account that owns the transit gateway multicast domain group resource.</p>
    pub fn get_resource_owner_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.resource_owner_id
    }
    /// <p>The ID of the transit gateway attachment.</p>
    pub fn network_interface_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.network_interface_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ID of the transit gateway attachment.</p>
    pub fn set_network_interface_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.network_interface_id = input;
        self
    }
    /// <p>The ID of the transit gateway attachment.</p>
    pub fn get_network_interface_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.network_interface_id
    }
    /// <p>Indicates that the resource is a transit gateway multicast group member.</p>
    pub fn group_member(mut self, input: bool) -> Self {
        self.group_member = ::std::option::Option::Some(input);
        self
    }
    /// <p>Indicates that the resource is a transit gateway multicast group member.</p>
    pub fn set_group_member(mut self, input: ::std::option::Option<bool>) -> Self {
        self.group_member = input;
        self
    }
    /// <p>Indicates that the resource is a transit gateway multicast group member.</p>
    pub fn get_group_member(&self) -> &::std::option::Option<bool> {
        &self.group_member
    }
    /// <p>Indicates that the resource is a transit gateway multicast group member.</p>
    pub fn group_source(mut self, input: bool) -> Self {
        self.group_source = ::std::option::Option::Some(input);
        self
    }
    /// <p>Indicates that the resource is a transit gateway multicast group member.</p>
    pub fn set_group_source(mut self, input: ::std::option::Option<bool>) -> Self {
        self.group_source = input;
        self
    }
    /// <p>Indicates that the resource is a transit gateway multicast group member.</p>
    pub fn get_group_source(&self) -> &::std::option::Option<bool> {
        &self.group_source
    }
    /// <p>The member type (for example, <code>static</code>).</p>
    pub fn member_type(mut self, input: crate::types::MembershipType) -> Self {
        self.member_type = ::std::option::Option::Some(input);
        self
    }
    /// <p>The member type (for example, <code>static</code>).</p>
    pub fn set_member_type(mut self, input: ::std::option::Option<crate::types::MembershipType>) -> Self {
        self.member_type = input;
        self
    }
    /// <p>The member type (for example, <code>static</code>).</p>
    pub fn get_member_type(&self) -> &::std::option::Option<crate::types::MembershipType> {
        &self.member_type
    }
    /// <p>The source type.</p>
    pub fn source_type(mut self, input: crate::types::MembershipType) -> Self {
        self.source_type = ::std::option::Option::Some(input);
        self
    }
    /// <p>The source type.</p>
    pub fn set_source_type(mut self, input: ::std::option::Option<crate::types::MembershipType>) -> Self {
        self.source_type = input;
        self
    }
    /// <p>The source type.</p>
    pub fn get_source_type(&self) -> &::std::option::Option<crate::types::MembershipType> {
        &self.source_type
    }
    /// Consumes the builder and constructs a [`TransitGatewayMulticastGroup`](crate::types::TransitGatewayMulticastGroup).
    pub fn build(self) -> crate::types::TransitGatewayMulticastGroup {
        crate::types::TransitGatewayMulticastGroup {
            group_ip_address: self.group_ip_address,
            transit_gateway_attachment_id: self.transit_gateway_attachment_id,
            subnet_id: self.subnet_id,
            resource_id: self.resource_id,
            resource_type: self.resource_type,
            resource_owner_id: self.resource_owner_id,
            network_interface_id: self.network_interface_id,
            group_member: self.group_member,
            group_source: self.group_source,
            member_type: self.member_type,
            source_type: self.source_type,
        }
    }
}