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
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.

/// Progressive Dialer config
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct ProgressiveDialerConfig {
    /// The bandwidth allocation of a queue resource.
    pub bandwidth_allocation: f64,
    /// Allocates dialing capacity for this campaign between multiple active campaigns
    pub dialing_capacity: ::std::option::Option<f64>,
}
impl ProgressiveDialerConfig {
    /// The bandwidth allocation of a queue resource.
    pub fn bandwidth_allocation(&self) -> f64 {
        self.bandwidth_allocation
    }
    /// Allocates dialing capacity for this campaign between multiple active campaigns
    pub fn dialing_capacity(&self) -> ::std::option::Option<f64> {
        self.dialing_capacity
    }
}
impl ProgressiveDialerConfig {
    /// Creates a new builder-style object to manufacture [`ProgressiveDialerConfig`](crate::types::ProgressiveDialerConfig).
    pub fn builder() -> crate::types::builders::ProgressiveDialerConfigBuilder {
        crate::types::builders::ProgressiveDialerConfigBuilder::default()
    }
}

/// A builder for [`ProgressiveDialerConfig`](crate::types::ProgressiveDialerConfig).
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct ProgressiveDialerConfigBuilder {
    pub(crate) bandwidth_allocation: ::std::option::Option<f64>,
    pub(crate) dialing_capacity: ::std::option::Option<f64>,
}
impl ProgressiveDialerConfigBuilder {
    /// The bandwidth allocation of a queue resource.
    /// This field is required.
    pub fn bandwidth_allocation(mut self, input: f64) -> Self {
        self.bandwidth_allocation = ::std::option::Option::Some(input);
        self
    }
    /// The bandwidth allocation of a queue resource.
    pub fn set_bandwidth_allocation(mut self, input: ::std::option::Option<f64>) -> Self {
        self.bandwidth_allocation = input;
        self
    }
    /// The bandwidth allocation of a queue resource.
    pub fn get_bandwidth_allocation(&self) -> &::std::option::Option<f64> {
        &self.bandwidth_allocation
    }
    /// Allocates dialing capacity for this campaign between multiple active campaigns
    pub fn dialing_capacity(mut self, input: f64) -> Self {
        self.dialing_capacity = ::std::option::Option::Some(input);
        self
    }
    /// Allocates dialing capacity for this campaign between multiple active campaigns
    pub fn set_dialing_capacity(mut self, input: ::std::option::Option<f64>) -> Self {
        self.dialing_capacity = input;
        self
    }
    /// Allocates dialing capacity for this campaign between multiple active campaigns
    pub fn get_dialing_capacity(&self) -> &::std::option::Option<f64> {
        &self.dialing_capacity
    }
    /// Consumes the builder and constructs a [`ProgressiveDialerConfig`](crate::types::ProgressiveDialerConfig).
    /// This method will fail if any of the following fields are not set:
    /// - [`bandwidth_allocation`](crate::types::builders::ProgressiveDialerConfigBuilder::bandwidth_allocation)
    pub fn build(self) -> ::std::result::Result<crate::types::ProgressiveDialerConfig, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::types::ProgressiveDialerConfig {
            bandwidth_allocation: self.bandwidth_allocation.ok_or_else(|| {
                ::aws_smithy_types::error::operation::BuildError::missing_field(
                    "bandwidth_allocation",
                    "bandwidth_allocation was not specified but it is required when building ProgressiveDialerConfig",
                )
            })?,
            dialing_capacity: self.dialing_capacity,
        })
    }
}