aws-sdk-glue 1.149.0

AWS SDK for AWS Glue
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 BatchGetBlueprintsOutput {
    /// <p>Returns a list of blueprint as a <code>Blueprints</code> object.</p>
    pub blueprints: ::std::option::Option<::std::vec::Vec<crate::types::Blueprint>>,
    /// <p>Returns a list of <code>BlueprintNames</code> that were not found.</p>
    pub missing_blueprints: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
    _request_id: Option<String>,
}
impl BatchGetBlueprintsOutput {
    /// <p>Returns a list of blueprint as a <code>Blueprints</code> object.</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 `.blueprints.is_none()`.
    pub fn blueprints(&self) -> &[crate::types::Blueprint] {
        self.blueprints.as_deref().unwrap_or_default()
    }
    /// <p>Returns a list of <code>BlueprintNames</code> that were not found.</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 `.missing_blueprints.is_none()`.
    pub fn missing_blueprints(&self) -> &[::std::string::String] {
        self.missing_blueprints.as_deref().unwrap_or_default()
    }
}
impl ::aws_types::request_id::RequestId for BatchGetBlueprintsOutput {
    fn request_id(&self) -> Option<&str> {
        self._request_id.as_deref()
    }
}
impl BatchGetBlueprintsOutput {
    /// Creates a new builder-style object to manufacture [`BatchGetBlueprintsOutput`](crate::operation::batch_get_blueprints::BatchGetBlueprintsOutput).
    pub fn builder() -> crate::operation::batch_get_blueprints::builders::BatchGetBlueprintsOutputBuilder {
        crate::operation::batch_get_blueprints::builders::BatchGetBlueprintsOutputBuilder::default()
    }
}

/// A builder for [`BatchGetBlueprintsOutput`](crate::operation::batch_get_blueprints::BatchGetBlueprintsOutput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct BatchGetBlueprintsOutputBuilder {
    pub(crate) blueprints: ::std::option::Option<::std::vec::Vec<crate::types::Blueprint>>,
    pub(crate) missing_blueprints: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
    _request_id: Option<String>,
}
impl BatchGetBlueprintsOutputBuilder {
    /// Appends an item to `blueprints`.
    ///
    /// To override the contents of this collection use [`set_blueprints`](Self::set_blueprints).
    ///
    /// <p>Returns a list of blueprint as a <code>Blueprints</code> object.</p>
    pub fn blueprints(mut self, input: crate::types::Blueprint) -> Self {
        let mut v = self.blueprints.unwrap_or_default();
        v.push(input);
        self.blueprints = ::std::option::Option::Some(v);
        self
    }
    /// <p>Returns a list of blueprint as a <code>Blueprints</code> object.</p>
    pub fn set_blueprints(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Blueprint>>) -> Self {
        self.blueprints = input;
        self
    }
    /// <p>Returns a list of blueprint as a <code>Blueprints</code> object.</p>
    pub fn get_blueprints(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Blueprint>> {
        &self.blueprints
    }
    /// Appends an item to `missing_blueprints`.
    ///
    /// To override the contents of this collection use [`set_missing_blueprints`](Self::set_missing_blueprints).
    ///
    /// <p>Returns a list of <code>BlueprintNames</code> that were not found.</p>
    pub fn missing_blueprints(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        let mut v = self.missing_blueprints.unwrap_or_default();
        v.push(input.into());
        self.missing_blueprints = ::std::option::Option::Some(v);
        self
    }
    /// <p>Returns a list of <code>BlueprintNames</code> that were not found.</p>
    pub fn set_missing_blueprints(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
        self.missing_blueprints = input;
        self
    }
    /// <p>Returns a list of <code>BlueprintNames</code> that were not found.</p>
    pub fn get_missing_blueprints(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
        &self.missing_blueprints
    }
    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 [`BatchGetBlueprintsOutput`](crate::operation::batch_get_blueprints::BatchGetBlueprintsOutput).
    pub fn build(self) -> crate::operation::batch_get_blueprints::BatchGetBlueprintsOutput {
        crate::operation::batch_get_blueprints::BatchGetBlueprintsOutput {
            blueprints: self.blueprints,
            missing_blueprints: self.missing_blueprints,
            _request_id: self._request_id,
        }
    }
}