aws-sdk-entityresolution 1.108.0

AWS SDK for AWS EntityResolution
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct DeletePolicyStatementInput {
    /// <p>The ARN of the resource for which the policy need to be deleted.</p>
    pub arn: ::std::option::Option<::std::string::String>,
    /// <p>A statement identifier that differentiates the statement from others in the same policy.</p>
    pub statement_id: ::std::option::Option<::std::string::String>,
}
impl DeletePolicyStatementInput {
    /// <p>The ARN of the resource for which the policy need to be deleted.</p>
    pub fn arn(&self) -> ::std::option::Option<&str> {
        self.arn.as_deref()
    }
    /// <p>A statement identifier that differentiates the statement from others in the same policy.</p>
    pub fn statement_id(&self) -> ::std::option::Option<&str> {
        self.statement_id.as_deref()
    }
}
impl DeletePolicyStatementInput {
    /// Creates a new builder-style object to manufacture [`DeletePolicyStatementInput`](crate::operation::delete_policy_statement::DeletePolicyStatementInput).
    pub fn builder() -> crate::operation::delete_policy_statement::builders::DeletePolicyStatementInputBuilder {
        crate::operation::delete_policy_statement::builders::DeletePolicyStatementInputBuilder::default()
    }
}

/// A builder for [`DeletePolicyStatementInput`](crate::operation::delete_policy_statement::DeletePolicyStatementInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct DeletePolicyStatementInputBuilder {
    pub(crate) arn: ::std::option::Option<::std::string::String>,
    pub(crate) statement_id: ::std::option::Option<::std::string::String>,
}
impl DeletePolicyStatementInputBuilder {
    /// <p>The ARN of the resource for which the policy need to be deleted.</p>
    /// This field is required.
    pub fn arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.arn = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ARN of the resource for which the policy need to be deleted.</p>
    pub fn set_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.arn = input;
        self
    }
    /// <p>The ARN of the resource for which the policy need to be deleted.</p>
    pub fn get_arn(&self) -> &::std::option::Option<::std::string::String> {
        &self.arn
    }
    /// <p>A statement identifier that differentiates the statement from others in the same policy.</p>
    /// This field is required.
    pub fn statement_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.statement_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>A statement identifier that differentiates the statement from others in the same policy.</p>
    pub fn set_statement_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.statement_id = input;
        self
    }
    /// <p>A statement identifier that differentiates the statement from others in the same policy.</p>
    pub fn get_statement_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.statement_id
    }
    /// Consumes the builder and constructs a [`DeletePolicyStatementInput`](crate::operation::delete_policy_statement::DeletePolicyStatementInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::delete_policy_statement::DeletePolicyStatementInput, ::aws_smithy_types::error::operation::BuildError>
    {
        ::std::result::Result::Ok(crate::operation::delete_policy_statement::DeletePolicyStatementInput {
            arn: self.arn,
            statement_id: self.statement_id,
        })
    }
}