Skip to main content

aws_sdk_securityhub/types/
_vpc_info_peering_options_details.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2
3/// <p>Provides information about the VPC peering connection options for the accepter or requester VPC.</p>
4#[non_exhaustive]
5#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
6pub struct VpcInfoPeeringOptionsDetails {
7    /// <p>Indicates whether a local VPC can resolve public DNS hostnames to private IP addresses when queried from instances in a peer VPC.</p>
8    pub allow_dns_resolution_from_remote_vpc: ::std::option::Option<bool>,
9    /// <p>Indicates whether a local ClassicLink connection can communicate with the peer VPC over the VPC peering connection.</p>
10    pub allow_egress_from_local_classic_link_to_remote_vpc: ::std::option::Option<bool>,
11    /// <p>Indicates whether a local VPC can communicate with a ClassicLink connection in the peer VPC over the VPC peering connection.</p>
12    pub allow_egress_from_local_vpc_to_remote_classic_link: ::std::option::Option<bool>,
13}
14impl VpcInfoPeeringOptionsDetails {
15    /// <p>Indicates whether a local VPC can resolve public DNS hostnames to private IP addresses when queried from instances in a peer VPC.</p>
16    pub fn allow_dns_resolution_from_remote_vpc(&self) -> ::std::option::Option<bool> {
17        self.allow_dns_resolution_from_remote_vpc
18    }
19    /// <p>Indicates whether a local ClassicLink connection can communicate with the peer VPC over the VPC peering connection.</p>
20    pub fn allow_egress_from_local_classic_link_to_remote_vpc(&self) -> ::std::option::Option<bool> {
21        self.allow_egress_from_local_classic_link_to_remote_vpc
22    }
23    /// <p>Indicates whether a local VPC can communicate with a ClassicLink connection in the peer VPC over the VPC peering connection.</p>
24    pub fn allow_egress_from_local_vpc_to_remote_classic_link(&self) -> ::std::option::Option<bool> {
25        self.allow_egress_from_local_vpc_to_remote_classic_link
26    }
27}
28impl VpcInfoPeeringOptionsDetails {
29    /// Creates a new builder-style object to manufacture [`VpcInfoPeeringOptionsDetails`](crate::types::VpcInfoPeeringOptionsDetails).
30    pub fn builder() -> crate::types::builders::VpcInfoPeeringOptionsDetailsBuilder {
31        crate::types::builders::VpcInfoPeeringOptionsDetailsBuilder::default()
32    }
33}
34
35/// A builder for [`VpcInfoPeeringOptionsDetails`](crate::types::VpcInfoPeeringOptionsDetails).
36#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
37#[non_exhaustive]
38pub struct VpcInfoPeeringOptionsDetailsBuilder {
39    pub(crate) allow_dns_resolution_from_remote_vpc: ::std::option::Option<bool>,
40    pub(crate) allow_egress_from_local_classic_link_to_remote_vpc: ::std::option::Option<bool>,
41    pub(crate) allow_egress_from_local_vpc_to_remote_classic_link: ::std::option::Option<bool>,
42}
43impl VpcInfoPeeringOptionsDetailsBuilder {
44    /// <p>Indicates whether a local VPC can resolve public DNS hostnames to private IP addresses when queried from instances in a peer VPC.</p>
45    pub fn allow_dns_resolution_from_remote_vpc(mut self, input: bool) -> Self {
46        self.allow_dns_resolution_from_remote_vpc = ::std::option::Option::Some(input);
47        self
48    }
49    /// <p>Indicates whether a local VPC can resolve public DNS hostnames to private IP addresses when queried from instances in a peer VPC.</p>
50    pub fn set_allow_dns_resolution_from_remote_vpc(mut self, input: ::std::option::Option<bool>) -> Self {
51        self.allow_dns_resolution_from_remote_vpc = input;
52        self
53    }
54    /// <p>Indicates whether a local VPC can resolve public DNS hostnames to private IP addresses when queried from instances in a peer VPC.</p>
55    pub fn get_allow_dns_resolution_from_remote_vpc(&self) -> &::std::option::Option<bool> {
56        &self.allow_dns_resolution_from_remote_vpc
57    }
58    /// <p>Indicates whether a local ClassicLink connection can communicate with the peer VPC over the VPC peering connection.</p>
59    pub fn allow_egress_from_local_classic_link_to_remote_vpc(mut self, input: bool) -> Self {
60        self.allow_egress_from_local_classic_link_to_remote_vpc = ::std::option::Option::Some(input);
61        self
62    }
63    /// <p>Indicates whether a local ClassicLink connection can communicate with the peer VPC over the VPC peering connection.</p>
64    pub fn set_allow_egress_from_local_classic_link_to_remote_vpc(mut self, input: ::std::option::Option<bool>) -> Self {
65        self.allow_egress_from_local_classic_link_to_remote_vpc = input;
66        self
67    }
68    /// <p>Indicates whether a local ClassicLink connection can communicate with the peer VPC over the VPC peering connection.</p>
69    pub fn get_allow_egress_from_local_classic_link_to_remote_vpc(&self) -> &::std::option::Option<bool> {
70        &self.allow_egress_from_local_classic_link_to_remote_vpc
71    }
72    /// <p>Indicates whether a local VPC can communicate with a ClassicLink connection in the peer VPC over the VPC peering connection.</p>
73    pub fn allow_egress_from_local_vpc_to_remote_classic_link(mut self, input: bool) -> Self {
74        self.allow_egress_from_local_vpc_to_remote_classic_link = ::std::option::Option::Some(input);
75        self
76    }
77    /// <p>Indicates whether a local VPC can communicate with a ClassicLink connection in the peer VPC over the VPC peering connection.</p>
78    pub fn set_allow_egress_from_local_vpc_to_remote_classic_link(mut self, input: ::std::option::Option<bool>) -> Self {
79        self.allow_egress_from_local_vpc_to_remote_classic_link = input;
80        self
81    }
82    /// <p>Indicates whether a local VPC can communicate with a ClassicLink connection in the peer VPC over the VPC peering connection.</p>
83    pub fn get_allow_egress_from_local_vpc_to_remote_classic_link(&self) -> &::std::option::Option<bool> {
84        &self.allow_egress_from_local_vpc_to_remote_classic_link
85    }
86    /// Consumes the builder and constructs a [`VpcInfoPeeringOptionsDetails`](crate::types::VpcInfoPeeringOptionsDetails).
87    pub fn build(self) -> crate::types::VpcInfoPeeringOptionsDetails {
88        crate::types::VpcInfoPeeringOptionsDetails {
89            allow_dns_resolution_from_remote_vpc: self.allow_dns_resolution_from_remote_vpc,
90            allow_egress_from_local_classic_link_to_remote_vpc: self.allow_egress_from_local_classic_link_to_remote_vpc,
91            allow_egress_from_local_vpc_to_remote_classic_link: self.allow_egress_from_local_vpc_to_remote_classic_link,
92        }
93    }
94}