#[allow(missing_docs)] #[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::fmt::Debug)]
pub struct CreateOutpostInput {
#[doc(hidden)]
pub name: std::option::Option<std::string::String>,
#[doc(hidden)]
pub description: std::option::Option<std::string::String>,
#[doc(hidden)]
pub site_id: std::option::Option<std::string::String>,
#[doc(hidden)]
pub availability_zone: std::option::Option<std::string::String>,
#[doc(hidden)]
pub availability_zone_id: std::option::Option<std::string::String>,
#[doc(hidden)]
pub tags:
std::option::Option<std::collections::HashMap<std::string::String, std::string::String>>,
#[doc(hidden)]
pub supported_hardware_type: std::option::Option<crate::types::SupportedHardwareType>,
}
impl CreateOutpostInput {
pub fn name(&self) -> std::option::Option<&str> {
self.name.as_deref()
}
pub fn description(&self) -> std::option::Option<&str> {
self.description.as_deref()
}
pub fn site_id(&self) -> std::option::Option<&str> {
self.site_id.as_deref()
}
pub fn availability_zone(&self) -> std::option::Option<&str> {
self.availability_zone.as_deref()
}
pub fn availability_zone_id(&self) -> std::option::Option<&str> {
self.availability_zone_id.as_deref()
}
pub fn tags(
&self,
) -> std::option::Option<&std::collections::HashMap<std::string::String, std::string::String>>
{
self.tags.as_ref()
}
pub fn supported_hardware_type(
&self,
) -> std::option::Option<&crate::types::SupportedHardwareType> {
self.supported_hardware_type.as_ref()
}
}
impl CreateOutpostInput {
pub fn builder() -> crate::operation::create_outpost::builders::CreateOutpostInputBuilder {
crate::operation::create_outpost::builders::CreateOutpostInputBuilder::default()
}
}
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct CreateOutpostInputBuilder {
pub(crate) name: std::option::Option<std::string::String>,
pub(crate) description: std::option::Option<std::string::String>,
pub(crate) site_id: std::option::Option<std::string::String>,
pub(crate) availability_zone: std::option::Option<std::string::String>,
pub(crate) availability_zone_id: std::option::Option<std::string::String>,
pub(crate) tags:
std::option::Option<std::collections::HashMap<std::string::String, std::string::String>>,
pub(crate) supported_hardware_type: std::option::Option<crate::types::SupportedHardwareType>,
}
impl CreateOutpostInputBuilder {
pub fn name(mut self, input: impl Into<std::string::String>) -> Self {
self.name = Some(input.into());
self
}
pub fn set_name(mut self, input: std::option::Option<std::string::String>) -> Self {
self.name = input;
self
}
pub fn description(mut self, input: impl Into<std::string::String>) -> Self {
self.description = Some(input.into());
self
}
pub fn set_description(mut self, input: std::option::Option<std::string::String>) -> Self {
self.description = input;
self
}
pub fn site_id(mut self, input: impl Into<std::string::String>) -> Self {
self.site_id = Some(input.into());
self
}
pub fn set_site_id(mut self, input: std::option::Option<std::string::String>) -> Self {
self.site_id = input;
self
}
pub fn availability_zone(mut self, input: impl Into<std::string::String>) -> Self {
self.availability_zone = Some(input.into());
self
}
pub fn set_availability_zone(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.availability_zone = input;
self
}
pub fn availability_zone_id(mut self, input: impl Into<std::string::String>) -> Self {
self.availability_zone_id = Some(input.into());
self
}
pub fn set_availability_zone_id(
mut self,
input: std::option::Option<std::string::String>,
) -> Self {
self.availability_zone_id = input;
self
}
pub fn tags(
mut self,
k: impl Into<std::string::String>,
v: impl Into<std::string::String>,
) -> Self {
let mut hash_map = self.tags.unwrap_or_default();
hash_map.insert(k.into(), v.into());
self.tags = Some(hash_map);
self
}
pub fn set_tags(
mut self,
input: std::option::Option<
std::collections::HashMap<std::string::String, std::string::String>,
>,
) -> Self {
self.tags = input;
self
}
pub fn supported_hardware_type(mut self, input: crate::types::SupportedHardwareType) -> Self {
self.supported_hardware_type = Some(input);
self
}
pub fn set_supported_hardware_type(
mut self,
input: std::option::Option<crate::types::SupportedHardwareType>,
) -> Self {
self.supported_hardware_type = input;
self
}
pub fn build(
self,
) -> Result<
crate::operation::create_outpost::CreateOutpostInput,
aws_smithy_http::operation::error::BuildError,
> {
Ok(crate::operation::create_outpost::CreateOutpostInput {
name: self.name,
description: self.description,
site_id: self.site_id,
availability_zone: self.availability_zone,
availability_zone_id: self.availability_zone_id,
tags: self.tags,
supported_hardware_type: self.supported_hardware_type,
})
}
}