aws_sdk_glue/operation/batch_delete_connection/
_batch_delete_connection_output.rs1#[allow(missing_docs)] #[non_exhaustive]
4#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
5pub struct BatchDeleteConnectionOutput {
6 pub succeeded: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
8 pub errors: ::std::option::Option<::std::collections::HashMap<::std::string::String, crate::types::ErrorDetail>>,
10 _request_id: Option<String>,
11}
12impl BatchDeleteConnectionOutput {
13 pub fn succeeded(&self) -> &[::std::string::String] {
17 self.succeeded.as_deref().unwrap_or_default()
18 }
19 pub fn errors(&self) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, crate::types::ErrorDetail>> {
21 self.errors.as_ref()
22 }
23}
24impl ::aws_types::request_id::RequestId for BatchDeleteConnectionOutput {
25 fn request_id(&self) -> Option<&str> {
26 self._request_id.as_deref()
27 }
28}
29impl BatchDeleteConnectionOutput {
30 pub fn builder() -> crate::operation::batch_delete_connection::builders::BatchDeleteConnectionOutputBuilder {
32 crate::operation::batch_delete_connection::builders::BatchDeleteConnectionOutputBuilder::default()
33 }
34}
35
36#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
38#[non_exhaustive]
39pub struct BatchDeleteConnectionOutputBuilder {
40 pub(crate) succeeded: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
41 pub(crate) errors: ::std::option::Option<::std::collections::HashMap<::std::string::String, crate::types::ErrorDetail>>,
42 _request_id: Option<String>,
43}
44impl BatchDeleteConnectionOutputBuilder {
45 pub fn succeeded(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
51 let mut v = self.succeeded.unwrap_or_default();
52 v.push(input.into());
53 self.succeeded = ::std::option::Option::Some(v);
54 self
55 }
56 pub fn set_succeeded(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
58 self.succeeded = input;
59 self
60 }
61 pub fn get_succeeded(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
63 &self.succeeded
64 }
65 pub fn errors(mut self, k: impl ::std::convert::Into<::std::string::String>, v: crate::types::ErrorDetail) -> Self {
71 let mut hash_map = self.errors.unwrap_or_default();
72 hash_map.insert(k.into(), v);
73 self.errors = ::std::option::Option::Some(hash_map);
74 self
75 }
76 pub fn set_errors(mut self, input: ::std::option::Option<::std::collections::HashMap<::std::string::String, crate::types::ErrorDetail>>) -> Self {
78 self.errors = input;
79 self
80 }
81 pub fn get_errors(&self) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, crate::types::ErrorDetail>> {
83 &self.errors
84 }
85 pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
86 self._request_id = Some(request_id.into());
87 self
88 }
89
90 pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
91 self._request_id = request_id;
92 self
93 }
94 pub fn build(self) -> crate::operation::batch_delete_connection::BatchDeleteConnectionOutput {
96 crate::operation::batch_delete_connection::BatchDeleteConnectionOutput {
97 succeeded: self.succeeded,
98 errors: self.errors,
99 _request_id: self._request_id,
100 }
101 }
102}