aws_sdk_ssoadmin/operation/list_account_assignment_creation_status/
_list_account_assignment_creation_status_output.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2#[allow(missing_docs)] // documentation missing in model
3#[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
5pub struct ListAccountAssignmentCreationStatusOutput {
6    /// <p>The status object for the account assignment creation operation.</p>
7    pub account_assignments_creation_status: ::std::option::Option<::std::vec::Vec<crate::types::AccountAssignmentOperationStatusMetadata>>,
8    /// <p>The pagination token for the list API. Initially the value is null. Use the output of previous API calls to make subsequent calls.</p>
9    pub next_token: ::std::option::Option<::std::string::String>,
10    _request_id: Option<String>,
11}
12impl ListAccountAssignmentCreationStatusOutput {
13    /// <p>The status object for the account assignment creation operation.</p>
14    ///
15    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.account_assignments_creation_status.is_none()`.
16    pub fn account_assignments_creation_status(&self) -> &[crate::types::AccountAssignmentOperationStatusMetadata] {
17        self.account_assignments_creation_status.as_deref().unwrap_or_default()
18    }
19    /// <p>The pagination token for the list API. Initially the value is null. Use the output of previous API calls to make subsequent calls.</p>
20    pub fn next_token(&self) -> ::std::option::Option<&str> {
21        self.next_token.as_deref()
22    }
23}
24impl ::aws_types::request_id::RequestId for ListAccountAssignmentCreationStatusOutput {
25    fn request_id(&self) -> Option<&str> {
26        self._request_id.as_deref()
27    }
28}
29impl ListAccountAssignmentCreationStatusOutput {
30    /// Creates a new builder-style object to manufacture [`ListAccountAssignmentCreationStatusOutput`](crate::operation::list_account_assignment_creation_status::ListAccountAssignmentCreationStatusOutput).
31    pub fn builder() -> crate::operation::list_account_assignment_creation_status::builders::ListAccountAssignmentCreationStatusOutputBuilder {
32        crate::operation::list_account_assignment_creation_status::builders::ListAccountAssignmentCreationStatusOutputBuilder::default()
33    }
34}
35
36/// A builder for [`ListAccountAssignmentCreationStatusOutput`](crate::operation::list_account_assignment_creation_status::ListAccountAssignmentCreationStatusOutput).
37#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
38#[non_exhaustive]
39pub struct ListAccountAssignmentCreationStatusOutputBuilder {
40    pub(crate) account_assignments_creation_status: ::std::option::Option<::std::vec::Vec<crate::types::AccountAssignmentOperationStatusMetadata>>,
41    pub(crate) next_token: ::std::option::Option<::std::string::String>,
42    _request_id: Option<String>,
43}
44impl ListAccountAssignmentCreationStatusOutputBuilder {
45    /// Appends an item to `account_assignments_creation_status`.
46    ///
47    /// To override the contents of this collection use [`set_account_assignments_creation_status`](Self::set_account_assignments_creation_status).
48    ///
49    /// <p>The status object for the account assignment creation operation.</p>
50    pub fn account_assignments_creation_status(mut self, input: crate::types::AccountAssignmentOperationStatusMetadata) -> Self {
51        let mut v = self.account_assignments_creation_status.unwrap_or_default();
52        v.push(input);
53        self.account_assignments_creation_status = ::std::option::Option::Some(v);
54        self
55    }
56    /// <p>The status object for the account assignment creation operation.</p>
57    pub fn set_account_assignments_creation_status(
58        mut self,
59        input: ::std::option::Option<::std::vec::Vec<crate::types::AccountAssignmentOperationStatusMetadata>>,
60    ) -> Self {
61        self.account_assignments_creation_status = input;
62        self
63    }
64    /// <p>The status object for the account assignment creation operation.</p>
65    pub fn get_account_assignments_creation_status(
66        &self,
67    ) -> &::std::option::Option<::std::vec::Vec<crate::types::AccountAssignmentOperationStatusMetadata>> {
68        &self.account_assignments_creation_status
69    }
70    /// <p>The pagination token for the list API. Initially the value is null. Use the output of previous API calls to make subsequent calls.</p>
71    pub fn next_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
72        self.next_token = ::std::option::Option::Some(input.into());
73        self
74    }
75    /// <p>The pagination token for the list API. Initially the value is null. Use the output of previous API calls to make subsequent calls.</p>
76    pub fn set_next_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
77        self.next_token = input;
78        self
79    }
80    /// <p>The pagination token for the list API. Initially the value is null. Use the output of previous API calls to make subsequent calls.</p>
81    pub fn get_next_token(&self) -> &::std::option::Option<::std::string::String> {
82        &self.next_token
83    }
84    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
85        self._request_id = Some(request_id.into());
86        self
87    }
88
89    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
90        self._request_id = request_id;
91        self
92    }
93    /// Consumes the builder and constructs a [`ListAccountAssignmentCreationStatusOutput`](crate::operation::list_account_assignment_creation_status::ListAccountAssignmentCreationStatusOutput).
94    pub fn build(self) -> crate::operation::list_account_assignment_creation_status::ListAccountAssignmentCreationStatusOutput {
95        crate::operation::list_account_assignment_creation_status::ListAccountAssignmentCreationStatusOutput {
96            account_assignments_creation_status: self.account_assignments_creation_status,
97            next_token: self.next_token,
98            _request_id: self._request_id,
99        }
100    }
101}