aws-sdk-oam 0.3.1

AWS SDK for CloudWatch Observability Access Manager
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 GetSinkPolicyInput {
    /// <p>The ARN of the sink to retrieve the policy of.</p>
    #[doc(hidden)]
    pub sink_identifier: std::option::Option<std::string::String>,
}
impl GetSinkPolicyInput {
    /// <p>The ARN of the sink to retrieve the policy of.</p>
    pub fn sink_identifier(&self) -> std::option::Option<&str> {
        self.sink_identifier.as_deref()
    }
}
impl GetSinkPolicyInput {
    /// Creates a new builder-style object to manufacture [`GetSinkPolicyInput`](crate::operation::get_sink_policy::GetSinkPolicyInput).
    pub fn builder() -> crate::operation::get_sink_policy::builders::GetSinkPolicyInputBuilder {
        crate::operation::get_sink_policy::builders::GetSinkPolicyInputBuilder::default()
    }
}

/// A builder for [`GetSinkPolicyInput`](crate::operation::get_sink_policy::GetSinkPolicyInput).
#[non_exhaustive]
#[derive(std::clone::Clone, std::cmp::PartialEq, std::default::Default, std::fmt::Debug)]
pub struct GetSinkPolicyInputBuilder {
    pub(crate) sink_identifier: std::option::Option<std::string::String>,
}
impl GetSinkPolicyInputBuilder {
    /// <p>The ARN of the sink to retrieve the policy of.</p>
    pub fn sink_identifier(mut self, input: impl Into<std::string::String>) -> Self {
        self.sink_identifier = Some(input.into());
        self
    }
    /// <p>The ARN of the sink to retrieve the policy of.</p>
    pub fn set_sink_identifier(mut self, input: std::option::Option<std::string::String>) -> Self {
        self.sink_identifier = input;
        self
    }
    /// Consumes the builder and constructs a [`GetSinkPolicyInput`](crate::operation::get_sink_policy::GetSinkPolicyInput).
    pub fn build(
        self,
    ) -> Result<
        crate::operation::get_sink_policy::GetSinkPolicyInput,
        aws_smithy_http::operation::error::BuildError,
    > {
        Ok(crate::operation::get_sink_policy::GetSinkPolicyInput {
            sink_identifier: self.sink_identifier,
        })
    }
}