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
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.

/// <p>Describes a route table.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct RouteTableIdentifier {
    /// <p>The ARN of the transit gateway route table for the attachment request. For example, <code>"TransitGatewayRouteTableArn": "arn:aws:ec2:us-west-2:123456789012:transit-gateway-route-table/tgw-rtb-9876543210123456"</code>.</p>
    pub transit_gateway_route_table_arn: ::std::option::Option<::std::string::String>,
    /// <p>The segment edge in a core network.</p>
    pub core_network_segment_edge: ::std::option::Option<crate::types::CoreNetworkSegmentEdgeIdentifier>,
}
impl RouteTableIdentifier {
    /// <p>The ARN of the transit gateway route table for the attachment request. For example, <code>"TransitGatewayRouteTableArn": "arn:aws:ec2:us-west-2:123456789012:transit-gateway-route-table/tgw-rtb-9876543210123456"</code>.</p>
    pub fn transit_gateway_route_table_arn(&self) -> ::std::option::Option<&str> {
        self.transit_gateway_route_table_arn.as_deref()
    }
    /// <p>The segment edge in a core network.</p>
    pub fn core_network_segment_edge(&self) -> ::std::option::Option<&crate::types::CoreNetworkSegmentEdgeIdentifier> {
        self.core_network_segment_edge.as_ref()
    }
}
impl RouteTableIdentifier {
    /// Creates a new builder-style object to manufacture [`RouteTableIdentifier`](crate::types::RouteTableIdentifier).
    pub fn builder() -> crate::types::builders::RouteTableIdentifierBuilder {
        crate::types::builders::RouteTableIdentifierBuilder::default()
    }
}

/// A builder for [`RouteTableIdentifier`](crate::types::RouteTableIdentifier).
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct RouteTableIdentifierBuilder {
    pub(crate) transit_gateway_route_table_arn: ::std::option::Option<::std::string::String>,
    pub(crate) core_network_segment_edge: ::std::option::Option<crate::types::CoreNetworkSegmentEdgeIdentifier>,
}
impl RouteTableIdentifierBuilder {
    /// <p>The ARN of the transit gateway route table for the attachment request. For example, <code>"TransitGatewayRouteTableArn": "arn:aws:ec2:us-west-2:123456789012:transit-gateway-route-table/tgw-rtb-9876543210123456"</code>.</p>
    pub fn transit_gateway_route_table_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.transit_gateway_route_table_arn = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ARN of the transit gateway route table for the attachment request. For example, <code>"TransitGatewayRouteTableArn": "arn:aws:ec2:us-west-2:123456789012:transit-gateway-route-table/tgw-rtb-9876543210123456"</code>.</p>
    pub fn set_transit_gateway_route_table_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.transit_gateway_route_table_arn = input;
        self
    }
    /// <p>The ARN of the transit gateway route table for the attachment request. For example, <code>"TransitGatewayRouteTableArn": "arn:aws:ec2:us-west-2:123456789012:transit-gateway-route-table/tgw-rtb-9876543210123456"</code>.</p>
    pub fn get_transit_gateway_route_table_arn(&self) -> &::std::option::Option<::std::string::String> {
        &self.transit_gateway_route_table_arn
    }
    /// <p>The segment edge in a core network.</p>
    pub fn core_network_segment_edge(mut self, input: crate::types::CoreNetworkSegmentEdgeIdentifier) -> Self {
        self.core_network_segment_edge = ::std::option::Option::Some(input);
        self
    }
    /// <p>The segment edge in a core network.</p>
    pub fn set_core_network_segment_edge(mut self, input: ::std::option::Option<crate::types::CoreNetworkSegmentEdgeIdentifier>) -> Self {
        self.core_network_segment_edge = input;
        self
    }
    /// <p>The segment edge in a core network.</p>
    pub fn get_core_network_segment_edge(&self) -> &::std::option::Option<crate::types::CoreNetworkSegmentEdgeIdentifier> {
        &self.core_network_segment_edge
    }
    /// Consumes the builder and constructs a [`RouteTableIdentifier`](crate::types::RouteTableIdentifier).
    pub fn build(self) -> crate::types::RouteTableIdentifier {
        crate::types::RouteTableIdentifier {
            transit_gateway_route_table_arn: self.transit_gateway_route_table_arn,
            core_network_segment_edge: self.core_network_segment_edge,
        }
    }
}