1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.

/// A request to update flow.
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct UpdateFlowInput {
    /// The flow that you want to update.
    pub flow_arn: ::std::option::Option<::std::string::String>,
    /// The settings for source failover.
    pub source_failover_config: ::std::option::Option<crate::types::UpdateFailoverConfig>,
    /// Update maintenance setting for a flow
    pub maintenance: ::std::option::Option<crate::types::UpdateMaintenance>,
}
impl UpdateFlowInput {
    /// The flow that you want to update.
    pub fn flow_arn(&self) -> ::std::option::Option<&str> {
        self.flow_arn.as_deref()
    }
    /// The settings for source failover.
    pub fn source_failover_config(&self) -> ::std::option::Option<&crate::types::UpdateFailoverConfig> {
        self.source_failover_config.as_ref()
    }
    /// Update maintenance setting for a flow
    pub fn maintenance(&self) -> ::std::option::Option<&crate::types::UpdateMaintenance> {
        self.maintenance.as_ref()
    }
}
impl UpdateFlowInput {
    /// Creates a new builder-style object to manufacture [`UpdateFlowInput`](crate::operation::update_flow::UpdateFlowInput).
    pub fn builder() -> crate::operation::update_flow::builders::UpdateFlowInputBuilder {
        crate::operation::update_flow::builders::UpdateFlowInputBuilder::default()
    }
}

/// A builder for [`UpdateFlowInput`](crate::operation::update_flow::UpdateFlowInput).
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct UpdateFlowInputBuilder {
    pub(crate) flow_arn: ::std::option::Option<::std::string::String>,
    pub(crate) source_failover_config: ::std::option::Option<crate::types::UpdateFailoverConfig>,
    pub(crate) maintenance: ::std::option::Option<crate::types::UpdateMaintenance>,
}
impl UpdateFlowInputBuilder {
    /// The flow that you want to update.
    /// This field is required.
    pub fn flow_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.flow_arn = ::std::option::Option::Some(input.into());
        self
    }
    /// The flow that you want to update.
    pub fn set_flow_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.flow_arn = input;
        self
    }
    /// The flow that you want to update.
    pub fn get_flow_arn(&self) -> &::std::option::Option<::std::string::String> {
        &self.flow_arn
    }
    /// The settings for source failover.
    pub fn source_failover_config(mut self, input: crate::types::UpdateFailoverConfig) -> Self {
        self.source_failover_config = ::std::option::Option::Some(input);
        self
    }
    /// The settings for source failover.
    pub fn set_source_failover_config(mut self, input: ::std::option::Option<crate::types::UpdateFailoverConfig>) -> Self {
        self.source_failover_config = input;
        self
    }
    /// The settings for source failover.
    pub fn get_source_failover_config(&self) -> &::std::option::Option<crate::types::UpdateFailoverConfig> {
        &self.source_failover_config
    }
    /// Update maintenance setting for a flow
    pub fn maintenance(mut self, input: crate::types::UpdateMaintenance) -> Self {
        self.maintenance = ::std::option::Option::Some(input);
        self
    }
    /// Update maintenance setting for a flow
    pub fn set_maintenance(mut self, input: ::std::option::Option<crate::types::UpdateMaintenance>) -> Self {
        self.maintenance = input;
        self
    }
    /// Update maintenance setting for a flow
    pub fn get_maintenance(&self) -> &::std::option::Option<crate::types::UpdateMaintenance> {
        &self.maintenance
    }
    /// Consumes the builder and constructs a [`UpdateFlowInput`](crate::operation::update_flow::UpdateFlowInput).
    pub fn build(self) -> ::std::result::Result<crate::operation::update_flow::UpdateFlowInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::update_flow::UpdateFlowInput {
            flow_arn: self.flow_arn,
            source_failover_config: self.source_failover_config,
            maintenance: self.maintenance,
        })
    }
}