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
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.

/// <p> Result structure used in response to request to delete a project. </p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct DeleteProjectOutput {
    /// <p> Resources which were deleted. </p>
    pub deleted_resources: ::std::option::Option<::std::vec::Vec<crate::types::Resource>>,
    /// <p> Resources which were not deleted, due to a risk of losing potentially important data or files. </p>
    pub orphaned_resources: ::std::option::Option<::std::vec::Vec<crate::types::Resource>>,
    _request_id: Option<String>,
}
impl DeleteProjectOutput {
    /// <p> Resources which were deleted. </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 `.deleted_resources.is_none()`.
    pub fn deleted_resources(&self) -> &[crate::types::Resource] {
        self.deleted_resources.as_deref().unwrap_or_default()
    }
    /// <p> Resources which were not deleted, due to a risk of losing potentially important data or files. </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 `.orphaned_resources.is_none()`.
    pub fn orphaned_resources(&self) -> &[crate::types::Resource] {
        self.orphaned_resources.as_deref().unwrap_or_default()
    }
}
impl ::aws_types::request_id::RequestId for DeleteProjectOutput {
    fn request_id(&self) -> Option<&str> {
        self._request_id.as_deref()
    }
}
impl DeleteProjectOutput {
    /// Creates a new builder-style object to manufacture [`DeleteProjectOutput`](crate::operation::delete_project::DeleteProjectOutput).
    pub fn builder() -> crate::operation::delete_project::builders::DeleteProjectOutputBuilder {
        crate::operation::delete_project::builders::DeleteProjectOutputBuilder::default()
    }
}

/// A builder for [`DeleteProjectOutput`](crate::operation::delete_project::DeleteProjectOutput).
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct DeleteProjectOutputBuilder {
    pub(crate) deleted_resources: ::std::option::Option<::std::vec::Vec<crate::types::Resource>>,
    pub(crate) orphaned_resources: ::std::option::Option<::std::vec::Vec<crate::types::Resource>>,
    _request_id: Option<String>,
}
impl DeleteProjectOutputBuilder {
    /// Appends an item to `deleted_resources`.
    ///
    /// To override the contents of this collection use [`set_deleted_resources`](Self::set_deleted_resources).
    ///
    /// <p> Resources which were deleted. </p>
    pub fn deleted_resources(mut self, input: crate::types::Resource) -> Self {
        let mut v = self.deleted_resources.unwrap_or_default();
        v.push(input);
        self.deleted_resources = ::std::option::Option::Some(v);
        self
    }
    /// <p> Resources which were deleted. </p>
    pub fn set_deleted_resources(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Resource>>) -> Self {
        self.deleted_resources = input;
        self
    }
    /// <p> Resources which were deleted. </p>
    pub fn get_deleted_resources(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Resource>> {
        &self.deleted_resources
    }
    /// Appends an item to `orphaned_resources`.
    ///
    /// To override the contents of this collection use [`set_orphaned_resources`](Self::set_orphaned_resources).
    ///
    /// <p> Resources which were not deleted, due to a risk of losing potentially important data or files. </p>
    pub fn orphaned_resources(mut self, input: crate::types::Resource) -> Self {
        let mut v = self.orphaned_resources.unwrap_or_default();
        v.push(input);
        self.orphaned_resources = ::std::option::Option::Some(v);
        self
    }
    /// <p> Resources which were not deleted, due to a risk of losing potentially important data or files. </p>
    pub fn set_orphaned_resources(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Resource>>) -> Self {
        self.orphaned_resources = input;
        self
    }
    /// <p> Resources which were not deleted, due to a risk of losing potentially important data or files. </p>
    pub fn get_orphaned_resources(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Resource>> {
        &self.orphaned_resources
    }
    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 [`DeleteProjectOutput`](crate::operation::delete_project::DeleteProjectOutput).
    pub fn build(self) -> crate::operation::delete_project::DeleteProjectOutput {
        crate::operation::delete_project::DeleteProjectOutput {
            deleted_resources: self.deleted_resources,
            orphaned_resources: self.orphaned_resources,
            _request_id: self._request_id,
        }
    }
}