aws-sdk-redshift 1.106.0

AWS SDK for Amazon Redshift
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 CreateHsmConfigurationOutput {
    /// <p>Returns information about an HSM configuration, which is an object that describes to Amazon Redshift clusters the information they require to connect to an HSM where they can store database encryption keys.</p>
    pub hsm_configuration: ::std::option::Option<crate::types::HsmConfiguration>,
    _request_id: Option<String>,
}
impl CreateHsmConfigurationOutput {
    /// <p>Returns information about an HSM configuration, which is an object that describes to Amazon Redshift clusters the information they require to connect to an HSM where they can store database encryption keys.</p>
    pub fn hsm_configuration(&self) -> ::std::option::Option<&crate::types::HsmConfiguration> {
        self.hsm_configuration.as_ref()
    }
}
impl ::aws_types::request_id::RequestId for CreateHsmConfigurationOutput {
    fn request_id(&self) -> Option<&str> {
        self._request_id.as_deref()
    }
}
impl CreateHsmConfigurationOutput {
    /// Creates a new builder-style object to manufacture [`CreateHsmConfigurationOutput`](crate::operation::create_hsm_configuration::CreateHsmConfigurationOutput).
    pub fn builder() -> crate::operation::create_hsm_configuration::builders::CreateHsmConfigurationOutputBuilder {
        crate::operation::create_hsm_configuration::builders::CreateHsmConfigurationOutputBuilder::default()
    }
}

/// A builder for [`CreateHsmConfigurationOutput`](crate::operation::create_hsm_configuration::CreateHsmConfigurationOutput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct CreateHsmConfigurationOutputBuilder {
    pub(crate) hsm_configuration: ::std::option::Option<crate::types::HsmConfiguration>,
    _request_id: Option<String>,
}
impl CreateHsmConfigurationOutputBuilder {
    /// <p>Returns information about an HSM configuration, which is an object that describes to Amazon Redshift clusters the information they require to connect to an HSM where they can store database encryption keys.</p>
    pub fn hsm_configuration(mut self, input: crate::types::HsmConfiguration) -> Self {
        self.hsm_configuration = ::std::option::Option::Some(input);
        self
    }
    /// <p>Returns information about an HSM configuration, which is an object that describes to Amazon Redshift clusters the information they require to connect to an HSM where they can store database encryption keys.</p>
    pub fn set_hsm_configuration(mut self, input: ::std::option::Option<crate::types::HsmConfiguration>) -> Self {
        self.hsm_configuration = input;
        self
    }
    /// <p>Returns information about an HSM configuration, which is an object that describes to Amazon Redshift clusters the information they require to connect to an HSM where they can store database encryption keys.</p>
    pub fn get_hsm_configuration(&self) -> &::std::option::Option<crate::types::HsmConfiguration> {
        &self.hsm_configuration
    }
    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
        self._request_id = Some(request_id.into());
        self
    }

    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
        self._request_id = request_id;
        self
    }
    /// Consumes the builder and constructs a [`CreateHsmConfigurationOutput`](crate::operation::create_hsm_configuration::CreateHsmConfigurationOutput).
    pub fn build(self) -> crate::operation::create_hsm_configuration::CreateHsmConfigurationOutput {
        crate::operation::create_hsm_configuration::CreateHsmConfigurationOutput {
            hsm_configuration: self.hsm_configuration,
            _request_id: self._request_id,
        }
    }
}