aws-sdk-agentregistrycontrol 1.0.0

AWS SDK for Agent Registry Control
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
pub use crate::operation::update_registry_record::_update_registry_record_input::UpdateRegistryRecordInputBuilder;

pub use crate::operation::update_registry_record::_update_registry_record_output::UpdateRegistryRecordOutputBuilder;

impl crate::operation::update_registry_record::builders::UpdateRegistryRecordInputBuilder {
    /// Sends a request with this input using the given client.
    pub async fn send_with(
        self,
        client: &crate::Client,
    ) -> ::std::result::Result<
        crate::operation::update_registry_record::UpdateRegistryRecordOutput,
        ::aws_smithy_runtime_api::client::result::SdkError<
            crate::operation::update_registry_record::UpdateRegistryRecordError,
            ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
        >,
    > {
        let mut fluent_builder = client.update_registry_record();
        fluent_builder.inner = self;
        fluent_builder.send().await
    }
}
/// Fluent builder constructing a request to `UpdateRegistryRecord`.
///
/// <p>Updates a registry record. The update is asynchronous: the record is returned with the UPDATING status while it is processed. Fields that use update wrappers follow PATCH semantics: omit the field to leave it unchanged.</p>
#[derive(::std::clone::Clone, ::std::fmt::Debug)]
pub struct UpdateRegistryRecordFluentBuilder {
    handle: ::std::sync::Arc<crate::client::Handle>,
    inner: crate::operation::update_registry_record::builders::UpdateRegistryRecordInputBuilder,
    config_override: ::std::option::Option<crate::config::Builder>,
}
impl
    crate::client::customize::internal::CustomizableSend<
        crate::operation::update_registry_record::UpdateRegistryRecordOutput,
        crate::operation::update_registry_record::UpdateRegistryRecordError,
    > for UpdateRegistryRecordFluentBuilder
{
    fn send(
        self,
        config_override: crate::config::Builder,
    ) -> crate::client::customize::internal::BoxFuture<
        crate::client::customize::internal::SendResult<
            crate::operation::update_registry_record::UpdateRegistryRecordOutput,
            crate::operation::update_registry_record::UpdateRegistryRecordError,
        >,
    > {
        ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
    }
}
impl UpdateRegistryRecordFluentBuilder {
    /// Creates a new `UpdateRegistryRecordFluentBuilder`.
    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 UpdateRegistryRecord as a reference.
    pub fn as_input(&self) -> &crate::operation::update_registry_record::builders::UpdateRegistryRecordInputBuilder {
        &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::update_registry_record::UpdateRegistryRecordOutput,
        ::aws_smithy_runtime_api::client::result::SdkError<
            crate::operation::update_registry_record::UpdateRegistryRecordError,
            ::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::update_registry_record::UpdateRegistryRecord::operation_runtime_plugins(
            self.handle.runtime_plugins.clone(),
            &self.handle.conf,
            self.config_override,
        );
        crate::operation::update_registry_record::UpdateRegistryRecord::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::update_registry_record::UpdateRegistryRecordOutput,
        crate::operation::update_registry_record::UpdateRegistryRecordError,
        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 identifier of the registry containing the record (ARN or ID)</p>
    pub fn registry_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.inner = self.inner.registry_id(input.into());
        self
    }
    /// <p>The identifier of the registry containing the record (ARN or ID)</p>
    pub fn set_registry_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.inner = self.inner.set_registry_id(input);
        self
    }
    /// <p>The identifier of the registry containing the record (ARN or ID)</p>
    pub fn get_registry_id(&self) -> &::std::option::Option<::std::string::String> {
        self.inner.get_registry_id()
    }
    /// <p>The identifier of the registry record to update (ARN or ID)</p>
    pub fn record_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.inner = self.inner.record_id(input.into());
        self
    }
    /// <p>The identifier of the registry record to update (ARN or ID)</p>
    pub fn set_record_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.inner = self.inner.set_record_id(input);
        self
    }
    /// <p>The identifier of the registry record to update (ARN or ID)</p>
    pub fn get_record_id(&self) -> &::std::option::Option<::std::string::String> {
        self.inner.get_record_id()
    }
    /// <p>The updated name of the registry record. Omit to leave the name unchanged.</p>
    pub fn name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.inner = self.inner.name(input.into());
        self
    }
    /// <p>The updated name of the registry record. Omit to leave the name unchanged.</p>
    pub fn set_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.inner = self.inner.set_name(input);
        self
    }
    /// <p>The updated name of the registry record. Omit to leave the name unchanged.</p>
    pub fn get_name(&self) -> &::std::option::Option<::std::string::String> {
        self.inner.get_name()
    }
    /// <p>The updated display name of the registry record. Omit to leave the display name unchanged; provide an empty wrapper to unset it.</p>
    pub fn display_name(mut self, input: crate::types::UpdatedDisplayName) -> Self {
        self.inner = self.inner.display_name(input);
        self
    }
    /// <p>The updated display name of the registry record. Omit to leave the display name unchanged; provide an empty wrapper to unset it.</p>
    pub fn set_display_name(mut self, input: ::std::option::Option<crate::types::UpdatedDisplayName>) -> Self {
        self.inner = self.inner.set_display_name(input);
        self
    }
    /// <p>The updated display name of the registry record. Omit to leave the display name unchanged; provide an empty wrapper to unset it.</p>
    pub fn get_display_name(&self) -> &::std::option::Option<crate::types::UpdatedDisplayName> {
        self.inner.get_display_name()
    }
    /// <p>The updated description of the registry record. Omit to leave the description unchanged; provide an empty wrapper to unset it.</p>
    pub fn description(mut self, input: crate::types::UpdatedDescription) -> Self {
        self.inner = self.inner.description(input);
        self
    }
    /// <p>The updated description of the registry record. Omit to leave the description unchanged; provide an empty wrapper to unset it.</p>
    pub fn set_description(mut self, input: ::std::option::Option<crate::types::UpdatedDescription>) -> Self {
        self.inner = self.inner.set_description(input);
        self
    }
    /// <p>The updated description of the registry record. Omit to leave the description unchanged; provide an empty wrapper to unset it.</p>
    pub fn get_description(&self) -> &::std::option::Option<crate::types::UpdatedDescription> {
        self.inner.get_description()
    }
    /// <p>The updated type of the registry record. Omit to leave the record type unchanged.</p>
    pub fn record_type(mut self, input: crate::types::RecordType) -> Self {
        self.inner = self.inner.record_type(input);
        self
    }
    /// <p>The updated type of the registry record. Omit to leave the record type unchanged.</p>
    pub fn set_record_type(mut self, input: ::std::option::Option<crate::types::RecordType>) -> Self {
        self.inner = self.inner.set_record_type(input);
        self
    }
    /// <p>The updated type of the registry record. Omit to leave the record type unchanged.</p>
    pub fn get_record_type(&self) -> &::std::option::Option<crate::types::RecordType> {
        self.inner.get_record_type()
    }
    /// <p>The updated typed descriptor content for the registry record. Omit to leave the descriptors unchanged.</p>
    pub fn descriptors(mut self, input: crate::types::UpdatedDescriptors) -> Self {
        self.inner = self.inner.descriptors(input);
        self
    }
    /// <p>The updated typed descriptor content for the registry record. Omit to leave the descriptors unchanged.</p>
    pub fn set_descriptors(mut self, input: ::std::option::Option<crate::types::UpdatedDescriptors>) -> Self {
        self.inner = self.inner.set_descriptors(input);
        self
    }
    /// <p>The updated typed descriptor content for the registry record. Omit to leave the descriptors unchanged.</p>
    pub fn get_descriptors(&self) -> &::std::option::Option<crate::types::UpdatedDescriptors> {
        self.inner.get_descriptors()
    }
    /// <p>The updated version of the registry record. Omit to leave the version unchanged.</p>
    pub fn record_version(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.inner = self.inner.record_version(input.into());
        self
    }
    /// <p>The updated version of the registry record. Omit to leave the version unchanged.</p>
    pub fn set_record_version(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.inner = self.inner.set_record_version(input);
        self
    }
    /// <p>The updated version of the registry record. Omit to leave the version unchanged.</p>
    pub fn get_record_version(&self) -> &::std::option::Option<::std::string::String> {
        self.inner.get_record_version()
    }
    /// <p>Whether to trigger synchronization of the record's descriptor content from its source</p>
    pub fn trigger_synchronization(mut self, input: bool) -> Self {
        self.inner = self.inner.trigger_synchronization(input);
        self
    }
    /// <p>Whether to trigger synchronization of the record's descriptor content from its source</p>
    pub fn set_trigger_synchronization(mut self, input: ::std::option::Option<bool>) -> Self {
        self.inner = self.inner.set_trigger_synchronization(input);
        self
    }
    /// <p>Whether to trigger synchronization of the record's descriptor content from its source</p>
    pub fn get_trigger_synchronization(&self) -> &::std::option::Option<bool> {
        self.inner.get_trigger_synchronization()
    }
}