#[allow(missing_docs)] #[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq)]
pub struct CreatePipeInput {
#[doc(hidden)]
pub name: ::std::option::Option<::std::string::String>,
#[doc(hidden)]
pub description: ::std::option::Option<::std::string::String>,
#[doc(hidden)]
pub desired_state: ::std::option::Option<crate::types::RequestedPipeState>,
#[doc(hidden)]
pub source: ::std::option::Option<::std::string::String>,
#[doc(hidden)]
pub source_parameters: ::std::option::Option<crate::types::PipeSourceParameters>,
#[doc(hidden)]
pub enrichment: ::std::option::Option<::std::string::String>,
#[doc(hidden)]
pub enrichment_parameters: ::std::option::Option<crate::types::PipeEnrichmentParameters>,
#[doc(hidden)]
pub target: ::std::option::Option<::std::string::String>,
#[doc(hidden)]
pub target_parameters: ::std::option::Option<crate::types::PipeTargetParameters>,
#[doc(hidden)]
pub role_arn: ::std::option::Option<::std::string::String>,
#[doc(hidden)]
pub tags: ::std::option::Option<
::std::collections::HashMap<::std::string::String, ::std::string::String>,
>,
}
impl CreatePipeInput {
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 desired_state(&self) -> ::std::option::Option<&crate::types::RequestedPipeState> {
self.desired_state.as_ref()
}
pub fn source(&self) -> ::std::option::Option<&str> {
self.source.as_deref()
}
pub fn source_parameters(&self) -> ::std::option::Option<&crate::types::PipeSourceParameters> {
self.source_parameters.as_ref()
}
pub fn enrichment(&self) -> ::std::option::Option<&str> {
self.enrichment.as_deref()
}
pub fn enrichment_parameters(
&self,
) -> ::std::option::Option<&crate::types::PipeEnrichmentParameters> {
self.enrichment_parameters.as_ref()
}
pub fn target(&self) -> ::std::option::Option<&str> {
self.target.as_deref()
}
pub fn target_parameters(&self) -> ::std::option::Option<&crate::types::PipeTargetParameters> {
self.target_parameters.as_ref()
}
pub fn role_arn(&self) -> ::std::option::Option<&str> {
self.role_arn.as_deref()
}
pub fn tags(
&self,
) -> ::std::option::Option<
&::std::collections::HashMap<::std::string::String, ::std::string::String>,
> {
self.tags.as_ref()
}
}
impl ::std::fmt::Debug for CreatePipeInput {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
let mut formatter = f.debug_struct("CreatePipeInput");
formatter.field("name", &self.name);
formatter.field("description", &"*** Sensitive Data Redacted ***");
formatter.field("desired_state", &self.desired_state);
formatter.field("source", &self.source);
formatter.field("source_parameters", &self.source_parameters);
formatter.field("enrichment", &self.enrichment);
formatter.field("enrichment_parameters", &self.enrichment_parameters);
formatter.field("target", &self.target);
formatter.field("target_parameters", &self.target_parameters);
formatter.field("role_arn", &self.role_arn);
formatter.field("tags", &self.tags);
formatter.finish()
}
}
impl CreatePipeInput {
pub fn builder() -> crate::operation::create_pipe::builders::CreatePipeInputBuilder {
crate::operation::create_pipe::builders::CreatePipeInputBuilder::default()
}
}
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default)]
pub struct CreatePipeInputBuilder {
pub(crate) name: ::std::option::Option<::std::string::String>,
pub(crate) description: ::std::option::Option<::std::string::String>,
pub(crate) desired_state: ::std::option::Option<crate::types::RequestedPipeState>,
pub(crate) source: ::std::option::Option<::std::string::String>,
pub(crate) source_parameters: ::std::option::Option<crate::types::PipeSourceParameters>,
pub(crate) enrichment: ::std::option::Option<::std::string::String>,
pub(crate) enrichment_parameters: ::std::option::Option<crate::types::PipeEnrichmentParameters>,
pub(crate) target: ::std::option::Option<::std::string::String>,
pub(crate) target_parameters: ::std::option::Option<crate::types::PipeTargetParameters>,
pub(crate) role_arn: ::std::option::Option<::std::string::String>,
pub(crate) tags: ::std::option::Option<
::std::collections::HashMap<::std::string::String, ::std::string::String>,
>,
}
impl CreatePipeInputBuilder {
pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.name = ::std::option::Option::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 ::std::convert::Into<::std::string::String>) -> Self {
self.description = ::std::option::Option::Some(input.into());
self
}
pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.description = input;
self
}
pub fn desired_state(mut self, input: crate::types::RequestedPipeState) -> Self {
self.desired_state = ::std::option::Option::Some(input);
self
}
pub fn set_desired_state(
mut self,
input: ::std::option::Option<crate::types::RequestedPipeState>,
) -> Self {
self.desired_state = input;
self
}
pub fn source(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.source = ::std::option::Option::Some(input.into());
self
}
pub fn set_source(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.source = input;
self
}
pub fn source_parameters(mut self, input: crate::types::PipeSourceParameters) -> Self {
self.source_parameters = ::std::option::Option::Some(input);
self
}
pub fn set_source_parameters(
mut self,
input: ::std::option::Option<crate::types::PipeSourceParameters>,
) -> Self {
self.source_parameters = input;
self
}
pub fn enrichment(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.enrichment = ::std::option::Option::Some(input.into());
self
}
pub fn set_enrichment(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.enrichment = input;
self
}
pub fn enrichment_parameters(mut self, input: crate::types::PipeEnrichmentParameters) -> Self {
self.enrichment_parameters = ::std::option::Option::Some(input);
self
}
pub fn set_enrichment_parameters(
mut self,
input: ::std::option::Option<crate::types::PipeEnrichmentParameters>,
) -> Self {
self.enrichment_parameters = input;
self
}
pub fn target(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.target = ::std::option::Option::Some(input.into());
self
}
pub fn set_target(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.target = input;
self
}
pub fn target_parameters(mut self, input: crate::types::PipeTargetParameters) -> Self {
self.target_parameters = ::std::option::Option::Some(input);
self
}
pub fn set_target_parameters(
mut self,
input: ::std::option::Option<crate::types::PipeTargetParameters>,
) -> Self {
self.target_parameters = input;
self
}
pub fn role_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.role_arn = ::std::option::Option::Some(input.into());
self
}
pub fn set_role_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.role_arn = input;
self
}
pub fn tags(
mut self,
k: impl ::std::convert::Into<::std::string::String>,
v: impl ::std::convert::Into<::std::string::String>,
) -> Self {
let mut hash_map = self.tags.unwrap_or_default();
hash_map.insert(k.into(), v.into());
self.tags = ::std::option::Option::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 build(
self,
) -> ::std::result::Result<
crate::operation::create_pipe::CreatePipeInput,
::aws_smithy_http::operation::error::BuildError,
> {
::std::result::Result::Ok(crate::operation::create_pipe::CreatePipeInput {
name: self.name,
description: self.description,
desired_state: self.desired_state,
source: self.source,
source_parameters: self.source_parameters,
enrichment: self.enrichment,
enrichment_parameters: self.enrichment_parameters,
target: self.target,
target_parameters: self.target_parameters,
role_arn: self.role_arn,
tags: self.tags,
})
}
}
impl ::std::fmt::Debug for CreatePipeInputBuilder {
fn fmt(&self, f: &mut ::std::fmt::Formatter<'_>) -> ::std::fmt::Result {
let mut formatter = f.debug_struct("CreatePipeInputBuilder");
formatter.field("name", &self.name);
formatter.field("description", &"*** Sensitive Data Redacted ***");
formatter.field("desired_state", &self.desired_state);
formatter.field("source", &self.source);
formatter.field("source_parameters", &self.source_parameters);
formatter.field("enrichment", &self.enrichment);
formatter.field("enrichment_parameters", &self.enrichment_parameters);
formatter.field("target", &self.target);
formatter.field("target_parameters", &self.target_parameters);
formatter.field("role_arn", &self.role_arn);
formatter.field("tags", &self.tags);
formatter.finish()
}
}