// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
pub use crate::operation::list_daemon_task_definitions::_list_daemon_task_definitions_input::ListDaemonTaskDefinitionsInputBuilder;
pub use crate::operation::list_daemon_task_definitions::_list_daemon_task_definitions_output::ListDaemonTaskDefinitionsOutputBuilder;
impl crate::operation::list_daemon_task_definitions::builders::ListDaemonTaskDefinitionsInputBuilder {
/// Sends a request with this input using the given client.
pub async fn send_with(
self,
client: &crate::Client,
) -> ::std::result::Result<
crate::operation::list_daemon_task_definitions::ListDaemonTaskDefinitionsOutput,
::aws_smithy_runtime_api::client::result::SdkError<
crate::operation::list_daemon_task_definitions::ListDaemonTaskDefinitionsError,
::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
>,
> {
let mut fluent_builder = client.list_daemon_task_definitions();
fluent_builder.inner = self;
fluent_builder.send().await
}
}
/// Fluent builder constructing a request to `ListDaemonTaskDefinitions`.
///
/// <p>Returns a list of daemon task definitions that are registered to your account. You can filter the results by family name, status, or both to find daemon task definitions that match your criteria.</p>
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
pub struct ListDaemonTaskDefinitionsFluentBuilder {
handle: ::std::sync::Arc<crate::client::Handle>,
inner: crate::operation::list_daemon_task_definitions::builders::ListDaemonTaskDefinitionsInputBuilder,
config_override: ::std::option::Option<crate::config::Builder>,
}
impl
crate::client::customize::internal::CustomizableSend<
crate::operation::list_daemon_task_definitions::ListDaemonTaskDefinitionsOutput,
crate::operation::list_daemon_task_definitions::ListDaemonTaskDefinitionsError,
> for ListDaemonTaskDefinitionsFluentBuilder
{
fn send(
self,
config_override: crate::config::Builder,
) -> crate::client::customize::internal::BoxFuture<
crate::client::customize::internal::SendResult<
crate::operation::list_daemon_task_definitions::ListDaemonTaskDefinitionsOutput,
crate::operation::list_daemon_task_definitions::ListDaemonTaskDefinitionsError,
>,
> {
::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
}
}
impl ListDaemonTaskDefinitionsFluentBuilder {
/// Creates a new `ListDaemonTaskDefinitionsFluentBuilder`.
pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
Self {
handle,
inner: ::std::default::Default::default(),
config_override: ::std::option::Option::None,
}
}
/// Access the ListDaemonTaskDefinitions as a reference.
pub fn as_input(&self) -> &crate::operation::list_daemon_task_definitions::builders::ListDaemonTaskDefinitionsInputBuilder {
&self.inner
}
/// Sends the request and returns the response.
///
/// If an error occurs, an `SdkError` will be returned with additional details that
/// can be matched against.
///
/// By default, any retryable failures will be retried twice. Retry behavior
/// is configurable with the [RetryConfig](aws_smithy_types::retry::RetryConfig), which can be
/// set when configuring the client.
pub async fn send(
self,
) -> ::std::result::Result<
crate::operation::list_daemon_task_definitions::ListDaemonTaskDefinitionsOutput,
::aws_smithy_runtime_api::client::result::SdkError<
crate::operation::list_daemon_task_definitions::ListDaemonTaskDefinitionsError,
::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
>,
> {
let input = self
.inner
.build()
.map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
let runtime_plugins = crate::operation::list_daemon_task_definitions::ListDaemonTaskDefinitions::operation_runtime_plugins(
self.handle.runtime_plugins.clone(),
&self.handle.conf,
self.config_override,
);
crate::operation::list_daemon_task_definitions::ListDaemonTaskDefinitions::orchestrate(&runtime_plugins, input).await
}
/// Consumes this builder, creating a customizable operation that can be modified before being sent.
pub fn customize(
self,
) -> crate::client::customize::CustomizableOperation<
crate::operation::list_daemon_task_definitions::ListDaemonTaskDefinitionsOutput,
crate::operation::list_daemon_task_definitions::ListDaemonTaskDefinitionsError,
Self,
> {
crate::client::customize::CustomizableOperation::new(self)
}
pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
self.set_config_override(::std::option::Option::Some(config_override.into()));
self
}
pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
self.config_override = config_override;
self
}
/// <p>The full family name to filter the <code>ListDaemonTaskDefinitions</code> results with. Specifying a <code>familyPrefix</code> limits the listed daemon task definitions to daemon task definition families that start with the <code>familyPrefix</code> string.</p>
pub fn family_prefix(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.inner = self.inner.family_prefix(input.into());
self
}
/// <p>The full family name to filter the <code>ListDaemonTaskDefinitions</code> results with. Specifying a <code>familyPrefix</code> limits the listed daemon task definitions to daemon task definition families that start with the <code>familyPrefix</code> string.</p>
pub fn set_family_prefix(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.inner = self.inner.set_family_prefix(input);
self
}
/// <p>The full family name to filter the <code>ListDaemonTaskDefinitions</code> results with. Specifying a <code>familyPrefix</code> limits the listed daemon task definitions to daemon task definition families that start with the <code>familyPrefix</code> string.</p>
pub fn get_family_prefix(&self) -> &::std::option::Option<::std::string::String> {
self.inner.get_family_prefix()
}
/// <p>The exact name of the daemon task definition family to filter results with.</p>
pub fn family(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.inner = self.inner.family(input.into());
self
}
/// <p>The exact name of the daemon task definition family to filter results with.</p>
pub fn set_family(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.inner = self.inner.set_family(input);
self
}
/// <p>The exact name of the daemon task definition family to filter results with.</p>
pub fn get_family(&self) -> &::std::option::Option<::std::string::String> {
self.inner.get_family()
}
/// <p>The revision filter to apply. Specify <code>LAST_REGISTERED</code> to return only the last registered revision for each daemon task definition family.</p>
pub fn revision(mut self, input: crate::types::DaemonTaskDefinitionRevisionFilter) -> Self {
self.inner = self.inner.revision(input);
self
}
/// <p>The revision filter to apply. Specify <code>LAST_REGISTERED</code> to return only the last registered revision for each daemon task definition family.</p>
pub fn set_revision(mut self, input: ::std::option::Option<crate::types::DaemonTaskDefinitionRevisionFilter>) -> Self {
self.inner = self.inner.set_revision(input);
self
}
/// <p>The revision filter to apply. Specify <code>LAST_REGISTERED</code> to return only the last registered revision for each daemon task definition family.</p>
pub fn get_revision(&self) -> &::std::option::Option<crate::types::DaemonTaskDefinitionRevisionFilter> {
self.inner.get_revision()
}
/// <p>The daemon task definition status to filter the <code>ListDaemonTaskDefinitions</code> results with. By default, only <code>ACTIVE</code> daemon task definitions are listed. If you set this parameter to <code>DELETE_IN_PROGRESS</code>, only daemon task definitions that are in the process of being deleted are listed. If you set this parameter to <code>ALL</code>, all daemon task definitions are listed regardless of status.</p>
pub fn status(mut self, input: crate::types::DaemonTaskDefinitionStatusFilter) -> Self {
self.inner = self.inner.status(input);
self
}
/// <p>The daemon task definition status to filter the <code>ListDaemonTaskDefinitions</code> results with. By default, only <code>ACTIVE</code> daemon task definitions are listed. If you set this parameter to <code>DELETE_IN_PROGRESS</code>, only daemon task definitions that are in the process of being deleted are listed. If you set this parameter to <code>ALL</code>, all daemon task definitions are listed regardless of status.</p>
pub fn set_status(mut self, input: ::std::option::Option<crate::types::DaemonTaskDefinitionStatusFilter>) -> Self {
self.inner = self.inner.set_status(input);
self
}
/// <p>The daemon task definition status to filter the <code>ListDaemonTaskDefinitions</code> results with. By default, only <code>ACTIVE</code> daemon task definitions are listed. If you set this parameter to <code>DELETE_IN_PROGRESS</code>, only daemon task definitions that are in the process of being deleted are listed. If you set this parameter to <code>ALL</code>, all daemon task definitions are listed regardless of status.</p>
pub fn get_status(&self) -> &::std::option::Option<crate::types::DaemonTaskDefinitionStatusFilter> {
self.inner.get_status()
}
/// <p>The order to sort the results. Valid values are <code>ASC</code> and <code>DESC</code>. By default (<code>ASC</code>), daemon task definitions are listed in ascending order by family name and revision number.</p>
pub fn sort(mut self, input: crate::types::SortOrder) -> Self {
self.inner = self.inner.sort(input);
self
}
/// <p>The order to sort the results. Valid values are <code>ASC</code> and <code>DESC</code>. By default (<code>ASC</code>), daemon task definitions are listed in ascending order by family name and revision number.</p>
pub fn set_sort(mut self, input: ::std::option::Option<crate::types::SortOrder>) -> Self {
self.inner = self.inner.set_sort(input);
self
}
/// <p>The order to sort the results. Valid values are <code>ASC</code> and <code>DESC</code>. By default (<code>ASC</code>), daemon task definitions are listed in ascending order by family name and revision number.</p>
pub fn get_sort(&self) -> &::std::option::Option<crate::types::SortOrder> {
self.inner.get_sort()
}
/// <p>The <code>nextToken</code> value returned from a <code>ListDaemonTaskDefinitions</code> request indicating that more results are available to fulfill the request and further calls will be needed. If <code>maxResults</code> was provided, it's possible for the number of results to be fewer than <code>maxResults</code>.</p><note>
/// <p>This token should be treated as an opaque identifier that is only used to retrieve the next items in a list and not for other programmatic purposes.</p>
/// </note>
pub fn next_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.inner = self.inner.next_token(input.into());
self
}
/// <p>The <code>nextToken</code> value returned from a <code>ListDaemonTaskDefinitions</code> request indicating that more results are available to fulfill the request and further calls will be needed. If <code>maxResults</code> was provided, it's possible for the number of results to be fewer than <code>maxResults</code>.</p><note>
/// <p>This token should be treated as an opaque identifier that is only used to retrieve the next items in a list and not for other programmatic purposes.</p>
/// </note>
pub fn set_next_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.inner = self.inner.set_next_token(input);
self
}
/// <p>The <code>nextToken</code> value returned from a <code>ListDaemonTaskDefinitions</code> request indicating that more results are available to fulfill the request and further calls will be needed. If <code>maxResults</code> was provided, it's possible for the number of results to be fewer than <code>maxResults</code>.</p><note>
/// <p>This token should be treated as an opaque identifier that is only used to retrieve the next items in a list and not for other programmatic purposes.</p>
/// </note>
pub fn get_next_token(&self) -> &::std::option::Option<::std::string::String> {
self.inner.get_next_token()
}
/// <p>The maximum number of daemon task definition results that <code>ListDaemonTaskDefinitions</code> returned in paginated output. When this parameter is used, <code>ListDaemonTaskDefinitions</code> only returns <code>maxResults</code> results in a single page along with a <code>nextToken</code> response element. The remaining results of the initial request can be seen by sending another <code>ListDaemonTaskDefinitions</code> request with the returned <code>nextToken</code> value. This value can be between 1 and 100. If this parameter isn't used, then <code>ListDaemonTaskDefinitions</code> returns up to 100 results and a <code>nextToken</code> value if applicable.</p>
pub fn max_results(mut self, input: i32) -> Self {
self.inner = self.inner.max_results(input);
self
}
/// <p>The maximum number of daemon task definition results that <code>ListDaemonTaskDefinitions</code> returned in paginated output. When this parameter is used, <code>ListDaemonTaskDefinitions</code> only returns <code>maxResults</code> results in a single page along with a <code>nextToken</code> response element. The remaining results of the initial request can be seen by sending another <code>ListDaemonTaskDefinitions</code> request with the returned <code>nextToken</code> value. This value can be between 1 and 100. If this parameter isn't used, then <code>ListDaemonTaskDefinitions</code> returns up to 100 results and a <code>nextToken</code> value if applicable.</p>
pub fn set_max_results(mut self, input: ::std::option::Option<i32>) -> Self {
self.inner = self.inner.set_max_results(input);
self
}
/// <p>The maximum number of daemon task definition results that <code>ListDaemonTaskDefinitions</code> returned in paginated output. When this parameter is used, <code>ListDaemonTaskDefinitions</code> only returns <code>maxResults</code> results in a single page along with a <code>nextToken</code> response element. The remaining results of the initial request can be seen by sending another <code>ListDaemonTaskDefinitions</code> request with the returned <code>nextToken</code> value. This value can be between 1 and 100. If this parameter isn't used, then <code>ListDaemonTaskDefinitions</code> returns up to 100 results and a <code>nextToken</code> value if applicable.</p>
pub fn get_max_results(&self) -> &::std::option::Option<i32> {
self.inner.get_max_results()
}
}