#[allow(missing_docs)] #[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct AllocateAddressOutput {
pub public_ip: ::std::option::Option<::std::string::String>,
pub allocation_id: ::std::option::Option<::std::string::String>,
pub public_ipv4_pool: ::std::option::Option<::std::string::String>,
pub network_border_group: ::std::option::Option<::std::string::String>,
pub domain: ::std::option::Option<crate::types::DomainType>,
pub customer_owned_ip: ::std::option::Option<::std::string::String>,
pub customer_owned_ipv4_pool: ::std::option::Option<::std::string::String>,
pub carrier_ip: ::std::option::Option<::std::string::String>,
_request_id: Option<String>,
}
impl AllocateAddressOutput {
pub fn public_ip(&self) -> ::std::option::Option<&str> {
self.public_ip.as_deref()
}
pub fn allocation_id(&self) -> ::std::option::Option<&str> {
self.allocation_id.as_deref()
}
pub fn public_ipv4_pool(&self) -> ::std::option::Option<&str> {
self.public_ipv4_pool.as_deref()
}
pub fn network_border_group(&self) -> ::std::option::Option<&str> {
self.network_border_group.as_deref()
}
pub fn domain(&self) -> ::std::option::Option<&crate::types::DomainType> {
self.domain.as_ref()
}
pub fn customer_owned_ip(&self) -> ::std::option::Option<&str> {
self.customer_owned_ip.as_deref()
}
pub fn customer_owned_ipv4_pool(&self) -> ::std::option::Option<&str> {
self.customer_owned_ipv4_pool.as_deref()
}
pub fn carrier_ip(&self) -> ::std::option::Option<&str> {
self.carrier_ip.as_deref()
}
}
impl ::aws_types::request_id::RequestId for AllocateAddressOutput {
fn request_id(&self) -> Option<&str> {
self._request_id.as_deref()
}
}
impl AllocateAddressOutput {
pub fn builder() -> crate::operation::allocate_address::builders::AllocateAddressOutputBuilder {
crate::operation::allocate_address::builders::AllocateAddressOutputBuilder::default()
}
}
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct AllocateAddressOutputBuilder {
pub(crate) public_ip: ::std::option::Option<::std::string::String>,
pub(crate) allocation_id: ::std::option::Option<::std::string::String>,
pub(crate) public_ipv4_pool: ::std::option::Option<::std::string::String>,
pub(crate) network_border_group: ::std::option::Option<::std::string::String>,
pub(crate) domain: ::std::option::Option<crate::types::DomainType>,
pub(crate) customer_owned_ip: ::std::option::Option<::std::string::String>,
pub(crate) customer_owned_ipv4_pool: ::std::option::Option<::std::string::String>,
pub(crate) carrier_ip: ::std::option::Option<::std::string::String>,
_request_id: Option<String>,
}
impl AllocateAddressOutputBuilder {
pub fn public_ip(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.public_ip = ::std::option::Option::Some(input.into());
self
}
pub fn set_public_ip(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.public_ip = input;
self
}
pub fn get_public_ip(&self) -> &::std::option::Option<::std::string::String> {
&self.public_ip
}
pub fn allocation_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.allocation_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_allocation_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.allocation_id = input;
self
}
pub fn get_allocation_id(&self) -> &::std::option::Option<::std::string::String> {
&self.allocation_id
}
pub fn public_ipv4_pool(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.public_ipv4_pool = ::std::option::Option::Some(input.into());
self
}
pub fn set_public_ipv4_pool(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.public_ipv4_pool = input;
self
}
pub fn get_public_ipv4_pool(&self) -> &::std::option::Option<::std::string::String> {
&self.public_ipv4_pool
}
pub fn network_border_group(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.network_border_group = ::std::option::Option::Some(input.into());
self
}
pub fn set_network_border_group(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.network_border_group = input;
self
}
pub fn get_network_border_group(&self) -> &::std::option::Option<::std::string::String> {
&self.network_border_group
}
pub fn domain(mut self, input: crate::types::DomainType) -> Self {
self.domain = ::std::option::Option::Some(input);
self
}
pub fn set_domain(mut self, input: ::std::option::Option<crate::types::DomainType>) -> Self {
self.domain = input;
self
}
pub fn get_domain(&self) -> &::std::option::Option<crate::types::DomainType> {
&self.domain
}
pub fn customer_owned_ip(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.customer_owned_ip = ::std::option::Option::Some(input.into());
self
}
pub fn set_customer_owned_ip(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.customer_owned_ip = input;
self
}
pub fn get_customer_owned_ip(&self) -> &::std::option::Option<::std::string::String> {
&self.customer_owned_ip
}
pub fn customer_owned_ipv4_pool(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.customer_owned_ipv4_pool = ::std::option::Option::Some(input.into());
self
}
pub fn set_customer_owned_ipv4_pool(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.customer_owned_ipv4_pool = input;
self
}
pub fn get_customer_owned_ipv4_pool(&self) -> &::std::option::Option<::std::string::String> {
&self.customer_owned_ipv4_pool
}
pub fn carrier_ip(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.carrier_ip = ::std::option::Option::Some(input.into());
self
}
pub fn set_carrier_ip(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.carrier_ip = input;
self
}
pub fn get_carrier_ip(&self) -> &::std::option::Option<::std::string::String> {
&self.carrier_ip
}
pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
self._request_id = Some(request_id.into());
self
}
pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
self._request_id = request_id;
self
}
pub fn build(self) -> crate::operation::allocate_address::AllocateAddressOutput {
crate::operation::allocate_address::AllocateAddressOutput {
public_ip: self.public_ip,
allocation_id: self.allocation_id,
public_ipv4_pool: self.public_ipv4_pool,
network_border_group: self.network_border_group,
domain: self.domain,
customer_owned_ip: self.customer_owned_ip,
customer_owned_ipv4_pool: self.customer_owned_ipv4_pool,
carrier_ip: self.carrier_ip,
_request_id: self._request_id,
}
}
}