aws_sdk_dynamodb/operation/describe_continuous_backups/
builders.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2pub use crate::operation::describe_continuous_backups::_describe_continuous_backups_output::DescribeContinuousBackupsOutputBuilder;
3
4pub use crate::operation::describe_continuous_backups::_describe_continuous_backups_input::DescribeContinuousBackupsInputBuilder;
5
6impl crate::operation::describe_continuous_backups::builders::DescribeContinuousBackupsInputBuilder {
7                    /// Sends a request with this input using the given client.
8                    pub async fn send_with(self, client: &crate::Client) -> ::std::result::Result<
9                        crate::operation::describe_continuous_backups::DescribeContinuousBackupsOutput,
10                        ::aws_smithy_runtime_api::client::result::SdkError<
11                            crate::operation::describe_continuous_backups::DescribeContinuousBackupsError,
12                            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse
13                        >
14                    > {
15                        let mut fluent_builder = client.describe_continuous_backups();
16                        fluent_builder.inner = self;
17                        fluent_builder.send().await
18                    }
19                }
20/// Fluent builder constructing a request to `DescribeContinuousBackups`.
21/// 
22/// <p>Checks the status of continuous backups and point in time recovery on the specified table. Continuous backups are <code>ENABLED</code> on all tables at table creation. If point in time recovery is enabled, <code>PointInTimeRecoveryStatus</code> will be set to ENABLED.</p>
23/// <p>After continuous backups and point in time recovery are enabled, you can restore to any point in time within <code>EarliestRestorableDateTime</code> and <code>LatestRestorableDateTime</code>.</p>
24/// <p><code>LatestRestorableDateTime</code> is typically 5 minutes before the current time. You can restore your table to any point in time in the last 35 days. You can set the recovery period to any value between 1 and 35 days.</p>
25/// <p>You can call <code>DescribeContinuousBackups</code> at a maximum rate of 10 times per second.</p>
26#[derive(::std::clone::Clone, ::std::fmt::Debug)]
27pub struct DescribeContinuousBackupsFluentBuilder {
28                handle: ::std::sync::Arc<crate::client::Handle>,
29                inner: crate::operation::describe_continuous_backups::builders::DescribeContinuousBackupsInputBuilder,
30config_override: ::std::option::Option<crate::config::Builder>,
31            }
32impl
33                crate::client::customize::internal::CustomizableSend<
34                    crate::operation::describe_continuous_backups::DescribeContinuousBackupsOutput,
35                    crate::operation::describe_continuous_backups::DescribeContinuousBackupsError,
36                > for DescribeContinuousBackupsFluentBuilder
37            {
38                fn send(
39                    self,
40                    config_override: crate::config::Builder,
41                ) -> crate::client::customize::internal::BoxFuture<
42                    crate::client::customize::internal::SendResult<
43                        crate::operation::describe_continuous_backups::DescribeContinuousBackupsOutput,
44                        crate::operation::describe_continuous_backups::DescribeContinuousBackupsError,
45                    >,
46                > {
47                    ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
48                }
49            }
50impl DescribeContinuousBackupsFluentBuilder {
51    /// Creates a new `DescribeContinuousBackupsFluentBuilder`.
52                    pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
53                        Self {
54                            handle,
55                            inner: ::std::default::Default::default(),
56    config_override: ::std::option::Option::None,
57                        }
58                    }
59    /// Access the DescribeContinuousBackups as a reference.
60                    pub fn as_input(&self) -> &crate::operation::describe_continuous_backups::builders::DescribeContinuousBackupsInputBuilder {
61                        &self.inner
62                    }
63    /// Sends the request and returns the response.
64                    ///
65                    /// If an error occurs, an `SdkError` will be returned with additional details that
66                    /// can be matched against.
67                    ///
68                    /// By default, any retryable failures will be retried twice. Retry behavior
69                    /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
70                    /// set when configuring the client.
71                    pub async fn send(self) -> ::std::result::Result<crate::operation::describe_continuous_backups::DescribeContinuousBackupsOutput, ::aws_smithy_runtime_api::client::result::SdkError<crate::operation::describe_continuous_backups::DescribeContinuousBackupsError, ::aws_smithy_runtime_api::client::orchestrator::HttpResponse>> {
72                        let input = self.inner.build().map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
73                        let runtime_plugins = crate::operation::describe_continuous_backups::DescribeContinuousBackups::operation_runtime_plugins(
74                            self.handle.runtime_plugins.clone(),
75                            &self.handle.conf,
76                            self.config_override,
77                        );
78                        crate::operation::describe_continuous_backups::DescribeContinuousBackups::orchestrate(&runtime_plugins, input).await
79                    }
80    
81                    /// Consumes this builder, creating a customizable operation that can be modified before being sent.
82                    pub fn customize(
83                        self,
84                    ) -> crate::client::customize::CustomizableOperation<crate::operation::describe_continuous_backups::DescribeContinuousBackupsOutput, crate::operation::describe_continuous_backups::DescribeContinuousBackupsError, Self> {
85                        crate::client::customize::CustomizableOperation::new(self)
86                    }
87    pub(crate) fn config_override(
88                            mut self,
89                            config_override: impl ::std::convert::Into<crate::config::Builder>,
90                        ) -> Self {
91                            self.set_config_override(::std::option::Option::Some(config_override.into()));
92                            self
93                        }
94    
95                        pub(crate) fn set_config_override(
96                            &mut self,
97                            config_override: ::std::option::Option<crate::config::Builder>,
98                        ) -> &mut Self {
99                            self.config_override = config_override;
100                            self
101                        }
102    /// <p>Name of the table for which the customer wants to check the continuous backups and point in time recovery settings.</p>
103    /// <p>You can also provide the Amazon Resource Name (ARN) of the table in this parameter.</p>
104    pub fn table_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
105                    self.inner = self.inner.table_name(input.into());
106                    self
107                }
108    /// <p>Name of the table for which the customer wants to check the continuous backups and point in time recovery settings.</p>
109    /// <p>You can also provide the Amazon Resource Name (ARN) of the table in this parameter.</p>
110    pub fn set_table_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
111                    self.inner = self.inner.set_table_name(input);
112                    self
113                }
114    /// <p>Name of the table for which the customer wants to check the continuous backups and point in time recovery settings.</p>
115    /// <p>You can also provide the Amazon Resource Name (ARN) of the table in this parameter.</p>
116    pub fn get_table_name(&self) -> &::std::option::Option<::std::string::String> {
117                    self.inner.get_table_name()
118                }
119}
120