aws-sdk-efs 1.63.0

AWS SDK for Amazon Elastic File System
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 DescribeAccessPointsOutput {
    /// <p>An array of access point descriptions.</p>
    pub access_points: ::std::option::Option<::std::vec::Vec<crate::types::AccessPointDescription>>,
    /// <p>Present if there are more access points than returned in the response. You can use the NextMarker in the subsequent request to fetch the additional descriptions.</p>
    pub next_token: ::std::option::Option<::std::string::String>,
    _request_id: Option<String>,
}
impl DescribeAccessPointsOutput {
    /// <p>An array of access point descriptions.</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 `.access_points.is_none()`.
    pub fn access_points(&self) -> &[crate::types::AccessPointDescription] {
        self.access_points.as_deref().unwrap_or_default()
    }
    /// <p>Present if there are more access points than returned in the response. You can use the NextMarker in the subsequent request to fetch the additional descriptions.</p>
    pub fn next_token(&self) -> ::std::option::Option<&str> {
        self.next_token.as_deref()
    }
}
impl ::aws_types::request_id::RequestId for DescribeAccessPointsOutput {
    fn request_id(&self) -> Option<&str> {
        self._request_id.as_deref()
    }
}
impl DescribeAccessPointsOutput {
    /// Creates a new builder-style object to manufacture [`DescribeAccessPointsOutput`](crate::operation::describe_access_points::DescribeAccessPointsOutput).
    pub fn builder() -> crate::operation::describe_access_points::builders::DescribeAccessPointsOutputBuilder {
        crate::operation::describe_access_points::builders::DescribeAccessPointsOutputBuilder::default()
    }
}

/// A builder for [`DescribeAccessPointsOutput`](crate::operation::describe_access_points::DescribeAccessPointsOutput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct DescribeAccessPointsOutputBuilder {
    pub(crate) access_points: ::std::option::Option<::std::vec::Vec<crate::types::AccessPointDescription>>,
    pub(crate) next_token: ::std::option::Option<::std::string::String>,
    _request_id: Option<String>,
}
impl DescribeAccessPointsOutputBuilder {
    /// Appends an item to `access_points`.
    ///
    /// To override the contents of this collection use [`set_access_points`](Self::set_access_points).
    ///
    /// <p>An array of access point descriptions.</p>
    pub fn access_points(mut self, input: crate::types::AccessPointDescription) -> Self {
        let mut v = self.access_points.unwrap_or_default();
        v.push(input);
        self.access_points = ::std::option::Option::Some(v);
        self
    }
    /// <p>An array of access point descriptions.</p>
    pub fn set_access_points(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::AccessPointDescription>>) -> Self {
        self.access_points = input;
        self
    }
    /// <p>An array of access point descriptions.</p>
    pub fn get_access_points(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::AccessPointDescription>> {
        &self.access_points
    }
    /// <p>Present if there are more access points than returned in the response. You can use the NextMarker in the subsequent request to fetch the additional descriptions.</p>
    pub fn next_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.next_token = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>Present if there are more access points than returned in the response. You can use the NextMarker in the subsequent request to fetch the additional descriptions.</p>
    pub fn set_next_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.next_token = input;
        self
    }
    /// <p>Present if there are more access points than returned in the response. You can use the NextMarker in the subsequent request to fetch the additional descriptions.</p>
    pub fn get_next_token(&self) -> &::std::option::Option<::std::string::String> {
        &self.next_token
    }
    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 [`DescribeAccessPointsOutput`](crate::operation::describe_access_points::DescribeAccessPointsOutput).
    pub fn build(self) -> crate::operation::describe_access_points::DescribeAccessPointsOutput {
        crate::operation::describe_access_points::DescribeAccessPointsOutput {
            access_points: self.access_points,
            next_token: self.next_token,
            _request_id: self._request_id,
        }
    }
}