aws-sdk-accessanalyzer 1.106.0

AWS SDK for Access Analyzer
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.

/// <p>Deletes an analyzer.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct DeleteAnalyzerInput {
    /// <p>The name of the analyzer to delete.</p>
    pub analyzer_name: ::std::option::Option<::std::string::String>,
    /// <p>A client token.</p>
    pub client_token: ::std::option::Option<::std::string::String>,
}
impl DeleteAnalyzerInput {
    /// <p>The name of the analyzer to delete.</p>
    pub fn analyzer_name(&self) -> ::std::option::Option<&str> {
        self.analyzer_name.as_deref()
    }
    /// <p>A client token.</p>
    pub fn client_token(&self) -> ::std::option::Option<&str> {
        self.client_token.as_deref()
    }
}
impl DeleteAnalyzerInput {
    /// Creates a new builder-style object to manufacture [`DeleteAnalyzerInput`](crate::operation::delete_analyzer::DeleteAnalyzerInput).
    pub fn builder() -> crate::operation::delete_analyzer::builders::DeleteAnalyzerInputBuilder {
        crate::operation::delete_analyzer::builders::DeleteAnalyzerInputBuilder::default()
    }
}

/// A builder for [`DeleteAnalyzerInput`](crate::operation::delete_analyzer::DeleteAnalyzerInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct DeleteAnalyzerInputBuilder {
    pub(crate) analyzer_name: ::std::option::Option<::std::string::String>,
    pub(crate) client_token: ::std::option::Option<::std::string::String>,
}
impl DeleteAnalyzerInputBuilder {
    /// <p>The name of the analyzer to delete.</p>
    /// This field is required.
    pub fn analyzer_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.analyzer_name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The name of the analyzer to delete.</p>
    pub fn set_analyzer_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.analyzer_name = input;
        self
    }
    /// <p>The name of the analyzer to delete.</p>
    pub fn get_analyzer_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.analyzer_name
    }
    /// <p>A client token.</p>
    pub fn client_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.client_token = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>A client token.</p>
    pub fn set_client_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.client_token = input;
        self
    }
    /// <p>A client token.</p>
    pub fn get_client_token(&self) -> &::std::option::Option<::std::string::String> {
        &self.client_token
    }
    /// Consumes the builder and constructs a [`DeleteAnalyzerInput`](crate::operation::delete_analyzer::DeleteAnalyzerInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::delete_analyzer::DeleteAnalyzerInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::delete_analyzer::DeleteAnalyzerInput {
            analyzer_name: self.analyzer_name,
            client_token: self.client_token,
        })
    }
}