aws-sdk-sfn 1.107.0

AWS SDK for AWS Step Functions
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct UpdateMapRunInput {
    /// <p>The Amazon Resource Name (ARN) of a Map Run.</p>
    pub map_run_arn: ::std::option::Option<::std::string::String>,
    /// <p>The maximum number of child workflow executions that can be specified to run in parallel for the Map Run at the same time.</p>
    pub max_concurrency: ::std::option::Option<i32>,
    /// <p>The maximum percentage of failed items before the Map Run fails.</p>
    pub tolerated_failure_percentage: ::std::option::Option<f32>,
    /// <p>The maximum number of failed items before the Map Run fails.</p>
    pub tolerated_failure_count: ::std::option::Option<i64>,
}
impl UpdateMapRunInput {
    /// <p>The Amazon Resource Name (ARN) of a Map Run.</p>
    pub fn map_run_arn(&self) -> ::std::option::Option<&str> {
        self.map_run_arn.as_deref()
    }
    /// <p>The maximum number of child workflow executions that can be specified to run in parallel for the Map Run at the same time.</p>
    pub fn max_concurrency(&self) -> ::std::option::Option<i32> {
        self.max_concurrency
    }
    /// <p>The maximum percentage of failed items before the Map Run fails.</p>
    pub fn tolerated_failure_percentage(&self) -> ::std::option::Option<f32> {
        self.tolerated_failure_percentage
    }
    /// <p>The maximum number of failed items before the Map Run fails.</p>
    pub fn tolerated_failure_count(&self) -> ::std::option::Option<i64> {
        self.tolerated_failure_count
    }
}
impl UpdateMapRunInput {
    /// Creates a new builder-style object to manufacture [`UpdateMapRunInput`](crate::operation::update_map_run::UpdateMapRunInput).
    pub fn builder() -> crate::operation::update_map_run::builders::UpdateMapRunInputBuilder {
        crate::operation::update_map_run::builders::UpdateMapRunInputBuilder::default()
    }
}

/// A builder for [`UpdateMapRunInput`](crate::operation::update_map_run::UpdateMapRunInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct UpdateMapRunInputBuilder {
    pub(crate) map_run_arn: ::std::option::Option<::std::string::String>,
    pub(crate) max_concurrency: ::std::option::Option<i32>,
    pub(crate) tolerated_failure_percentage: ::std::option::Option<f32>,
    pub(crate) tolerated_failure_count: ::std::option::Option<i64>,
}
impl UpdateMapRunInputBuilder {
    /// <p>The Amazon Resource Name (ARN) of a Map Run.</p>
    /// This field is required.
    pub fn map_run_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.map_run_arn = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The Amazon Resource Name (ARN) of a Map Run.</p>
    pub fn set_map_run_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.map_run_arn = input;
        self
    }
    /// <p>The Amazon Resource Name (ARN) of a Map Run.</p>
    pub fn get_map_run_arn(&self) -> &::std::option::Option<::std::string::String> {
        &self.map_run_arn
    }
    /// <p>The maximum number of child workflow executions that can be specified to run in parallel for the Map Run at the same time.</p>
    pub fn max_concurrency(mut self, input: i32) -> Self {
        self.max_concurrency = ::std::option::Option::Some(input);
        self
    }
    /// <p>The maximum number of child workflow executions that can be specified to run in parallel for the Map Run at the same time.</p>
    pub fn set_max_concurrency(mut self, input: ::std::option::Option<i32>) -> Self {
        self.max_concurrency = input;
        self
    }
    /// <p>The maximum number of child workflow executions that can be specified to run in parallel for the Map Run at the same time.</p>
    pub fn get_max_concurrency(&self) -> &::std::option::Option<i32> {
        &self.max_concurrency
    }
    /// <p>The maximum percentage of failed items before the Map Run fails.</p>
    pub fn tolerated_failure_percentage(mut self, input: f32) -> Self {
        self.tolerated_failure_percentage = ::std::option::Option::Some(input);
        self
    }
    /// <p>The maximum percentage of failed items before the Map Run fails.</p>
    pub fn set_tolerated_failure_percentage(mut self, input: ::std::option::Option<f32>) -> Self {
        self.tolerated_failure_percentage = input;
        self
    }
    /// <p>The maximum percentage of failed items before the Map Run fails.</p>
    pub fn get_tolerated_failure_percentage(&self) -> &::std::option::Option<f32> {
        &self.tolerated_failure_percentage
    }
    /// <p>The maximum number of failed items before the Map Run fails.</p>
    pub fn tolerated_failure_count(mut self, input: i64) -> Self {
        self.tolerated_failure_count = ::std::option::Option::Some(input);
        self
    }
    /// <p>The maximum number of failed items before the Map Run fails.</p>
    pub fn set_tolerated_failure_count(mut self, input: ::std::option::Option<i64>) -> Self {
        self.tolerated_failure_count = input;
        self
    }
    /// <p>The maximum number of failed items before the Map Run fails.</p>
    pub fn get_tolerated_failure_count(&self) -> &::std::option::Option<i64> {
        &self.tolerated_failure_count
    }
    /// Consumes the builder and constructs a [`UpdateMapRunInput`](crate::operation::update_map_run::UpdateMapRunInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::update_map_run::UpdateMapRunInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::update_map_run::UpdateMapRunInput {
            map_run_arn: self.map_run_arn,
            max_concurrency: self.max_concurrency,
            tolerated_failure_percentage: self.tolerated_failure_percentage,
            tolerated_failure_count: self.tolerated_failure_count,
        })
    }
}