aws-sdk-securityhub 1.109.0

AWS SDK for AWS SecurityHub
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 BatchDisableStandardsOutput {
    /// <p>The details of the standards subscriptions that were disabled.</p>
    pub standards_subscriptions: ::std::option::Option<::std::vec::Vec<crate::types::StandardsSubscription>>,
    _request_id: Option<String>,
}
impl BatchDisableStandardsOutput {
    /// <p>The details of the standards subscriptions that were disabled.</p>
    ///
    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.standards_subscriptions.is_none()`.
    pub fn standards_subscriptions(&self) -> &[crate::types::StandardsSubscription] {
        self.standards_subscriptions.as_deref().unwrap_or_default()
    }
}
impl ::aws_types::request_id::RequestId for BatchDisableStandardsOutput {
    fn request_id(&self) -> Option<&str> {
        self._request_id.as_deref()
    }
}
impl BatchDisableStandardsOutput {
    /// Creates a new builder-style object to manufacture [`BatchDisableStandardsOutput`](crate::operation::batch_disable_standards::BatchDisableStandardsOutput).
    pub fn builder() -> crate::operation::batch_disable_standards::builders::BatchDisableStandardsOutputBuilder {
        crate::operation::batch_disable_standards::builders::BatchDisableStandardsOutputBuilder::default()
    }
}

/// A builder for [`BatchDisableStandardsOutput`](crate::operation::batch_disable_standards::BatchDisableStandardsOutput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct BatchDisableStandardsOutputBuilder {
    pub(crate) standards_subscriptions: ::std::option::Option<::std::vec::Vec<crate::types::StandardsSubscription>>,
    _request_id: Option<String>,
}
impl BatchDisableStandardsOutputBuilder {
    /// Appends an item to `standards_subscriptions`.
    ///
    /// To override the contents of this collection use [`set_standards_subscriptions`](Self::set_standards_subscriptions).
    ///
    /// <p>The details of the standards subscriptions that were disabled.</p>
    pub fn standards_subscriptions(mut self, input: crate::types::StandardsSubscription) -> Self {
        let mut v = self.standards_subscriptions.unwrap_or_default();
        v.push(input);
        self.standards_subscriptions = ::std::option::Option::Some(v);
        self
    }
    /// <p>The details of the standards subscriptions that were disabled.</p>
    pub fn set_standards_subscriptions(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::StandardsSubscription>>) -> Self {
        self.standards_subscriptions = input;
        self
    }
    /// <p>The details of the standards subscriptions that were disabled.</p>
    pub fn get_standards_subscriptions(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::StandardsSubscription>> {
        &self.standards_subscriptions
    }
    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 [`BatchDisableStandardsOutput`](crate::operation::batch_disable_standards::BatchDisableStandardsOutput).
    pub fn build(self) -> crate::operation::batch_disable_standards::BatchDisableStandardsOutput {
        crate::operation::batch_disable_standards::BatchDisableStandardsOutput {
            standards_subscriptions: self.standards_subscriptions,
            _request_id: self._request_id,
        }
    }
}