1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129
// 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 DisassociateFacesOutput {
    /// <p>An array of DissociatedFace objects containing FaceIds that are successfully disassociated with the UserID is returned. Returned if the DisassociatedFaces action is successful.</p>
    pub disassociated_faces: ::std::option::Option<::std::vec::Vec<crate::types::DisassociatedFace>>,
    /// <p>An array of UnsuccessfulDisassociation objects containing FaceIds that are not successfully associated, along with the reasons for the failure to associate. Returned if the DisassociateFaces action is successful.</p>
    pub unsuccessful_face_disassociations: ::std::option::Option<::std::vec::Vec<crate::types::UnsuccessfulFaceDisassociation>>,
    /// <p>The status of an update made to a User. Reflects if the User has been updated for every requested change.</p>
    pub user_status: ::std::option::Option<crate::types::UserStatus>,
    _request_id: Option<String>,
}
impl DisassociateFacesOutput {
    /// <p>An array of DissociatedFace objects containing FaceIds that are successfully disassociated with the UserID is returned. Returned if the DisassociatedFaces action is successful.</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 `.disassociated_faces.is_none()`.
    pub fn disassociated_faces(&self) -> &[crate::types::DisassociatedFace] {
        self.disassociated_faces.as_deref().unwrap_or_default()
    }
    /// <p>An array of UnsuccessfulDisassociation objects containing FaceIds that are not successfully associated, along with the reasons for the failure to associate. Returned if the DisassociateFaces action is successful.</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 `.unsuccessful_face_disassociations.is_none()`.
    pub fn unsuccessful_face_disassociations(&self) -> &[crate::types::UnsuccessfulFaceDisassociation] {
        self.unsuccessful_face_disassociations.as_deref().unwrap_or_default()
    }
    /// <p>The status of an update made to a User. Reflects if the User has been updated for every requested change.</p>
    pub fn user_status(&self) -> ::std::option::Option<&crate::types::UserStatus> {
        self.user_status.as_ref()
    }
}
impl ::aws_types::request_id::RequestId for DisassociateFacesOutput {
    fn request_id(&self) -> Option<&str> {
        self._request_id.as_deref()
    }
}
impl DisassociateFacesOutput {
    /// Creates a new builder-style object to manufacture [`DisassociateFacesOutput`](crate::operation::disassociate_faces::DisassociateFacesOutput).
    pub fn builder() -> crate::operation::disassociate_faces::builders::DisassociateFacesOutputBuilder {
        crate::operation::disassociate_faces::builders::DisassociateFacesOutputBuilder::default()
    }
}
/// A builder for [`DisassociateFacesOutput`](crate::operation::disassociate_faces::DisassociateFacesOutput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct DisassociateFacesOutputBuilder {
    pub(crate) disassociated_faces: ::std::option::Option<::std::vec::Vec<crate::types::DisassociatedFace>>,
    pub(crate) unsuccessful_face_disassociations: ::std::option::Option<::std::vec::Vec<crate::types::UnsuccessfulFaceDisassociation>>,
    pub(crate) user_status: ::std::option::Option<crate::types::UserStatus>,
    _request_id: Option<String>,
}
impl DisassociateFacesOutputBuilder {
    /// Appends an item to `disassociated_faces`.
    ///
    /// To override the contents of this collection use [`set_disassociated_faces`](Self::set_disassociated_faces).
    ///
    /// <p>An array of DissociatedFace objects containing FaceIds that are successfully disassociated with the UserID is returned. Returned if the DisassociatedFaces action is successful.</p>
    pub fn disassociated_faces(mut self, input: crate::types::DisassociatedFace) -> Self {
        let mut v = self.disassociated_faces.unwrap_or_default();
        v.push(input);
        self.disassociated_faces = ::std::option::Option::Some(v);
        self
    }
    /// <p>An array of DissociatedFace objects containing FaceIds that are successfully disassociated with the UserID is returned. Returned if the DisassociatedFaces action is successful.</p>
    pub fn set_disassociated_faces(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::DisassociatedFace>>) -> Self {
        self.disassociated_faces = input;
        self
    }
    /// <p>An array of DissociatedFace objects containing FaceIds that are successfully disassociated with the UserID is returned. Returned if the DisassociatedFaces action is successful.</p>
    pub fn get_disassociated_faces(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::DisassociatedFace>> {
        &self.disassociated_faces
    }
    /// Appends an item to `unsuccessful_face_disassociations`.
    ///
    /// To override the contents of this collection use [`set_unsuccessful_face_disassociations`](Self::set_unsuccessful_face_disassociations).
    ///
    /// <p>An array of UnsuccessfulDisassociation objects containing FaceIds that are not successfully associated, along with the reasons for the failure to associate. Returned if the DisassociateFaces action is successful.</p>
    pub fn unsuccessful_face_disassociations(mut self, input: crate::types::UnsuccessfulFaceDisassociation) -> Self {
        let mut v = self.unsuccessful_face_disassociations.unwrap_or_default();
        v.push(input);
        self.unsuccessful_face_disassociations = ::std::option::Option::Some(v);
        self
    }
    /// <p>An array of UnsuccessfulDisassociation objects containing FaceIds that are not successfully associated, along with the reasons for the failure to associate. Returned if the DisassociateFaces action is successful.</p>
    pub fn set_unsuccessful_face_disassociations(
        mut self,
        input: ::std::option::Option<::std::vec::Vec<crate::types::UnsuccessfulFaceDisassociation>>,
    ) -> Self {
        self.unsuccessful_face_disassociations = input;
        self
    }
    /// <p>An array of UnsuccessfulDisassociation objects containing FaceIds that are not successfully associated, along with the reasons for the failure to associate. Returned if the DisassociateFaces action is successful.</p>
    pub fn get_unsuccessful_face_disassociations(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::UnsuccessfulFaceDisassociation>> {
        &self.unsuccessful_face_disassociations
    }
    /// <p>The status of an update made to a User. Reflects if the User has been updated for every requested change.</p>
    pub fn user_status(mut self, input: crate::types::UserStatus) -> Self {
        self.user_status = ::std::option::Option::Some(input);
        self
    }
    /// <p>The status of an update made to a User. Reflects if the User has been updated for every requested change.</p>
    pub fn set_user_status(mut self, input: ::std::option::Option<crate::types::UserStatus>) -> Self {
        self.user_status = input;
        self
    }
    /// <p>The status of an update made to a User. Reflects if the User has been updated for every requested change.</p>
    pub fn get_user_status(&self) -> &::std::option::Option<crate::types::UserStatus> {
        &self.user_status
    }
    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 [`DisassociateFacesOutput`](crate::operation::disassociate_faces::DisassociateFacesOutput).
    pub fn build(self) -> crate::operation::disassociate_faces::DisassociateFacesOutput {
        crate::operation::disassociate_faces::DisassociateFacesOutput {
            disassociated_faces: self.disassociated_faces,
            unsuccessful_face_disassociations: self.unsuccessful_face_disassociations,
            user_status: self.user_status,
            _request_id: self._request_id,
        }
    }
}