aws_sdk_databasemigration/operation/describe_fleet_advisor_schemas/
builders.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2pub use crate::operation::describe_fleet_advisor_schemas::_describe_fleet_advisor_schemas_output::DescribeFleetAdvisorSchemasOutputBuilder;
3
4pub use crate::operation::describe_fleet_advisor_schemas::_describe_fleet_advisor_schemas_input::DescribeFleetAdvisorSchemasInputBuilder;
5
6impl crate::operation::describe_fleet_advisor_schemas::builders::DescribeFleetAdvisorSchemasInputBuilder {
7    /// Sends a request with this input using the given client.
8    pub async fn send_with(
9        self,
10        client: &crate::Client,
11    ) -> ::std::result::Result<
12        crate::operation::describe_fleet_advisor_schemas::DescribeFleetAdvisorSchemasOutput,
13        ::aws_smithy_runtime_api::client::result::SdkError<
14            crate::operation::describe_fleet_advisor_schemas::DescribeFleetAdvisorSchemasError,
15            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
16        >,
17    > {
18        let mut fluent_builder = client.describe_fleet_advisor_schemas();
19        fluent_builder.inner = self;
20        fluent_builder.send().await
21    }
22}
23/// Fluent builder constructing a request to `DescribeFleetAdvisorSchemas`.
24///
25/// <important>
26/// <p>End of support notice: On May 20, 2026, Amazon Web Services will end support for Amazon Web Services DMS Fleet Advisor;. After May 20, 2026, you will no longer be able to access the Amazon Web Services DMS Fleet Advisor; console or Amazon Web Services DMS Fleet Advisor; resources. For more information, see <a href="https://docs.aws.amazon.com/dms/latest/userguide/dms_fleet.advisor-end-of-support.html">Amazon Web Services DMS Fleet Advisor end of support</a>.</p>
27/// </important>
28/// <p>Returns a list of schemas detected by Fleet Advisor Collectors in your account.</p>
29#[derive(::std::clone::Clone, ::std::fmt::Debug)]
30pub struct DescribeFleetAdvisorSchemasFluentBuilder {
31    handle: ::std::sync::Arc<crate::client::Handle>,
32    inner: crate::operation::describe_fleet_advisor_schemas::builders::DescribeFleetAdvisorSchemasInputBuilder,
33    config_override: ::std::option::Option<crate::config::Builder>,
34}
35impl
36    crate::client::customize::internal::CustomizableSend<
37        crate::operation::describe_fleet_advisor_schemas::DescribeFleetAdvisorSchemasOutput,
38        crate::operation::describe_fleet_advisor_schemas::DescribeFleetAdvisorSchemasError,
39    > for DescribeFleetAdvisorSchemasFluentBuilder
40{
41    fn send(
42        self,
43        config_override: crate::config::Builder,
44    ) -> crate::client::customize::internal::BoxFuture<
45        crate::client::customize::internal::SendResult<
46            crate::operation::describe_fleet_advisor_schemas::DescribeFleetAdvisorSchemasOutput,
47            crate::operation::describe_fleet_advisor_schemas::DescribeFleetAdvisorSchemasError,
48        >,
49    > {
50        ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
51    }
52}
53impl DescribeFleetAdvisorSchemasFluentBuilder {
54    /// Creates a new `DescribeFleetAdvisorSchemasFluentBuilder`.
55    pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
56        Self {
57            handle,
58            inner: ::std::default::Default::default(),
59            config_override: ::std::option::Option::None,
60        }
61    }
62    /// Access the DescribeFleetAdvisorSchemas as a reference.
63    pub fn as_input(&self) -> &crate::operation::describe_fleet_advisor_schemas::builders::DescribeFleetAdvisorSchemasInputBuilder {
64        &self.inner
65    }
66    /// Sends the request and returns the response.
67    ///
68    /// If an error occurs, an `SdkError` will be returned with additional details that
69    /// can be matched against.
70    ///
71    /// By default, any retryable failures will be retried twice. Retry behavior
72    /// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
73    /// set when configuring the client.
74    pub async fn send(
75        self,
76    ) -> ::std::result::Result<
77        crate::operation::describe_fleet_advisor_schemas::DescribeFleetAdvisorSchemasOutput,
78        ::aws_smithy_runtime_api::client::result::SdkError<
79            crate::operation::describe_fleet_advisor_schemas::DescribeFleetAdvisorSchemasError,
80            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
81        >,
82    > {
83        let input = self
84            .inner
85            .build()
86            .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
87        let runtime_plugins = crate::operation::describe_fleet_advisor_schemas::DescribeFleetAdvisorSchemas::operation_runtime_plugins(
88            self.handle.runtime_plugins.clone(),
89            &self.handle.conf,
90            self.config_override,
91        );
92        crate::operation::describe_fleet_advisor_schemas::DescribeFleetAdvisorSchemas::orchestrate(&runtime_plugins, input).await
93    }
94
95    /// Consumes this builder, creating a customizable operation that can be modified before being sent.
96    pub fn customize(
97        self,
98    ) -> crate::client::customize::CustomizableOperation<
99        crate::operation::describe_fleet_advisor_schemas::DescribeFleetAdvisorSchemasOutput,
100        crate::operation::describe_fleet_advisor_schemas::DescribeFleetAdvisorSchemasError,
101        Self,
102    > {
103        crate::client::customize::CustomizableOperation::new(self)
104    }
105    pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
106        self.set_config_override(::std::option::Option::Some(config_override.into()));
107        self
108    }
109
110    pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
111        self.config_override = config_override;
112        self
113    }
114    /// Create a paginator for this request
115    ///
116    /// Paginators are used by calling [`send().await`](crate::operation::describe_fleet_advisor_schemas::paginator::DescribeFleetAdvisorSchemasPaginator::send) which returns a [`PaginationStream`](aws_smithy_async::future::pagination_stream::PaginationStream).
117    pub fn into_paginator(self) -> crate::operation::describe_fleet_advisor_schemas::paginator::DescribeFleetAdvisorSchemasPaginator {
118        crate::operation::describe_fleet_advisor_schemas::paginator::DescribeFleetAdvisorSchemasPaginator::new(self.handle, self.inner)
119    }
120    ///
121    /// Appends an item to `Filters`.
122    ///
123    /// To override the contents of this collection use [`set_filters`](Self::set_filters).
124    ///
125    /// <p>If you specify any of the following filters, the output includes information for only those schemas that meet the filter criteria:</p>
126    /// <ul>
127    /// <li>
128    /// <p><code>complexity</code> – The schema's complexity, for example <code>Simple</code>.</p></li>
129    /// <li>
130    /// <p><code>database-id</code> – The ID of the schema's database.</p></li>
131    /// <li>
132    /// <p><code>database-ip-address</code> – The IP address of the schema's database.</p></li>
133    /// <li>
134    /// <p><code>database-name</code> – The name of the schema's database.</p></li>
135    /// <li>
136    /// <p><code>database-engine</code> – The name of the schema database's engine.</p></li>
137    /// <li>
138    /// <p><code>original-schema-name</code> – The name of the schema's database's main schema.</p></li>
139    /// <li>
140    /// <p><code>schema-id</code> – The ID of the schema, for example <code>15</code>.</p></li>
141    /// <li>
142    /// <p><code>schema-name</code> – The name of the schema.</p></li>
143    /// <li>
144    /// <p><code>server-ip-address</code> – The IP address of the schema database's server.</p></li>
145    /// </ul>
146    /// <p>An example is: <code>describe-fleet-advisor-schemas --filter Name="schema-id",Values="50"</code></p>
147    pub fn filters(mut self, input: crate::types::Filter) -> Self {
148        self.inner = self.inner.filters(input);
149        self
150    }
151    /// <p>If you specify any of the following filters, the output includes information for only those schemas that meet the filter criteria:</p>
152    /// <ul>
153    /// <li>
154    /// <p><code>complexity</code> – The schema's complexity, for example <code>Simple</code>.</p></li>
155    /// <li>
156    /// <p><code>database-id</code> – The ID of the schema's database.</p></li>
157    /// <li>
158    /// <p><code>database-ip-address</code> – The IP address of the schema's database.</p></li>
159    /// <li>
160    /// <p><code>database-name</code> – The name of the schema's database.</p></li>
161    /// <li>
162    /// <p><code>database-engine</code> – The name of the schema database's engine.</p></li>
163    /// <li>
164    /// <p><code>original-schema-name</code> – The name of the schema's database's main schema.</p></li>
165    /// <li>
166    /// <p><code>schema-id</code> – The ID of the schema, for example <code>15</code>.</p></li>
167    /// <li>
168    /// <p><code>schema-name</code> – The name of the schema.</p></li>
169    /// <li>
170    /// <p><code>server-ip-address</code> – The IP address of the schema database's server.</p></li>
171    /// </ul>
172    /// <p>An example is: <code>describe-fleet-advisor-schemas --filter Name="schema-id",Values="50"</code></p>
173    pub fn set_filters(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Filter>>) -> Self {
174        self.inner = self.inner.set_filters(input);
175        self
176    }
177    /// <p>If you specify any of the following filters, the output includes information for only those schemas that meet the filter criteria:</p>
178    /// <ul>
179    /// <li>
180    /// <p><code>complexity</code> – The schema's complexity, for example <code>Simple</code>.</p></li>
181    /// <li>
182    /// <p><code>database-id</code> – The ID of the schema's database.</p></li>
183    /// <li>
184    /// <p><code>database-ip-address</code> – The IP address of the schema's database.</p></li>
185    /// <li>
186    /// <p><code>database-name</code> – The name of the schema's database.</p></li>
187    /// <li>
188    /// <p><code>database-engine</code> – The name of the schema database's engine.</p></li>
189    /// <li>
190    /// <p><code>original-schema-name</code> – The name of the schema's database's main schema.</p></li>
191    /// <li>
192    /// <p><code>schema-id</code> – The ID of the schema, for example <code>15</code>.</p></li>
193    /// <li>
194    /// <p><code>schema-name</code> – The name of the schema.</p></li>
195    /// <li>
196    /// <p><code>server-ip-address</code> – The IP address of the schema database's server.</p></li>
197    /// </ul>
198    /// <p>An example is: <code>describe-fleet-advisor-schemas --filter Name="schema-id",Values="50"</code></p>
199    pub fn get_filters(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Filter>> {
200        self.inner.get_filters()
201    }
202    /// <p>Sets the maximum number of records returned in the response.</p>
203    pub fn max_records(mut self, input: i32) -> Self {
204        self.inner = self.inner.max_records(input);
205        self
206    }
207    /// <p>Sets the maximum number of records returned in the response.</p>
208    pub fn set_max_records(mut self, input: ::std::option::Option<i32>) -> Self {
209        self.inner = self.inner.set_max_records(input);
210        self
211    }
212    /// <p>Sets the maximum number of records returned in the response.</p>
213    pub fn get_max_records(&self) -> &::std::option::Option<i32> {
214        self.inner.get_max_records()
215    }
216    /// <p>If <code>NextToken</code> is returned by a previous response, there are more results available. The value of <code>NextToken</code> is a unique pagination token for each page. Make the call again using the returned token to retrieve the next page. Keep all other arguments unchanged.</p>
217    pub fn next_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
218        self.inner = self.inner.next_token(input.into());
219        self
220    }
221    /// <p>If <code>NextToken</code> is returned by a previous response, there are more results available. The value of <code>NextToken</code> is a unique pagination token for each page. Make the call again using the returned token to retrieve the next page. Keep all other arguments unchanged.</p>
222    pub fn set_next_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
223        self.inner = self.inner.set_next_token(input);
224        self
225    }
226    /// <p>If <code>NextToken</code> is returned by a previous response, there are more results available. The value of <code>NextToken</code> is a unique pagination token for each page. Make the call again using the returned token to retrieve the next page. Keep all other arguments unchanged.</p>
227    pub fn get_next_token(&self) -> &::std::option::Option<::std::string::String> {
228        self.inner.get_next_token()
229    }
230}