#[allow(missing_docs)] #[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct UpdateCustomActionInput {
pub custom_action_arn: ::std::option::Option<::std::string::String>,
pub definition: ::std::option::Option<crate::types::CustomActionDefinition>,
pub alias_name: ::std::option::Option<::std::string::String>,
pub attachments: ::std::option::Option<::std::vec::Vec<crate::types::CustomActionAttachment>>,
}
impl UpdateCustomActionInput {
pub fn custom_action_arn(&self) -> ::std::option::Option<&str> {
self.custom_action_arn.as_deref()
}
pub fn definition(&self) -> ::std::option::Option<&crate::types::CustomActionDefinition> {
self.definition.as_ref()
}
pub fn alias_name(&self) -> ::std::option::Option<&str> {
self.alias_name.as_deref()
}
pub fn attachments(&self) -> &[crate::types::CustomActionAttachment] {
self.attachments.as_deref().unwrap_or_default()
}
}
impl UpdateCustomActionInput {
pub fn builder() -> crate::operation::update_custom_action::builders::UpdateCustomActionInputBuilder {
crate::operation::update_custom_action::builders::UpdateCustomActionInputBuilder::default()
}
}
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct UpdateCustomActionInputBuilder {
pub(crate) custom_action_arn: ::std::option::Option<::std::string::String>,
pub(crate) definition: ::std::option::Option<crate::types::CustomActionDefinition>,
pub(crate) alias_name: ::std::option::Option<::std::string::String>,
pub(crate) attachments: ::std::option::Option<::std::vec::Vec<crate::types::CustomActionAttachment>>,
}
impl UpdateCustomActionInputBuilder {
pub fn custom_action_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.custom_action_arn = ::std::option::Option::Some(input.into());
self
}
pub fn set_custom_action_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.custom_action_arn = input;
self
}
pub fn get_custom_action_arn(&self) -> &::std::option::Option<::std::string::String> {
&self.custom_action_arn
}
pub fn definition(mut self, input: crate::types::CustomActionDefinition) -> Self {
self.definition = ::std::option::Option::Some(input);
self
}
pub fn set_definition(mut self, input: ::std::option::Option<crate::types::CustomActionDefinition>) -> Self {
self.definition = input;
self
}
pub fn get_definition(&self) -> &::std::option::Option<crate::types::CustomActionDefinition> {
&self.definition
}
pub fn alias_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.alias_name = ::std::option::Option::Some(input.into());
self
}
pub fn set_alias_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.alias_name = input;
self
}
pub fn get_alias_name(&self) -> &::std::option::Option<::std::string::String> {
&self.alias_name
}
pub fn attachments(mut self, input: crate::types::CustomActionAttachment) -> Self {
let mut v = self.attachments.unwrap_or_default();
v.push(input);
self.attachments = ::std::option::Option::Some(v);
self
}
pub fn set_attachments(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::CustomActionAttachment>>) -> Self {
self.attachments = input;
self
}
pub fn get_attachments(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::CustomActionAttachment>> {
&self.attachments
}
pub fn build(
self,
) -> ::std::result::Result<crate::operation::update_custom_action::UpdateCustomActionInput, ::aws_smithy_types::error::operation::BuildError>
{
::std::result::Result::Ok(crate::operation::update_custom_action::UpdateCustomActionInput {
custom_action_arn: self.custom_action_arn,
definition: self.definition,
alias_name: self.alias_name,
attachments: self.attachments,
})
}
}