aws_sdk_ram/operation/delete_permission/
_delete_permission_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 DeletePermissionOutput {
6    /// <p>A boolean that indicates whether the delete operations succeeded.</p>
7    pub return_value: ::std::option::Option<bool>,
8    /// <p>The idempotency identifier associated with this request. If you want to repeat the same operation in an idempotent manner then you must include this value in the <code>clientToken</code> request parameter of that later call. All other parameters must also have the same values that you used in the first call.</p>
9    pub client_token: ::std::option::Option<::std::string::String>,
10    /// <p>This operation is performed asynchronously, and this response parameter indicates the current status.</p>
11    pub permission_status: ::std::option::Option<crate::types::PermissionStatus>,
12    _request_id: Option<String>,
13}
14impl DeletePermissionOutput {
15    /// <p>A boolean that indicates whether the delete operations succeeded.</p>
16    pub fn return_value(&self) -> ::std::option::Option<bool> {
17        self.return_value
18    }
19    /// <p>The idempotency identifier associated with this request. If you want to repeat the same operation in an idempotent manner then you must include this value in the <code>clientToken</code> request parameter of that later call. All other parameters must also have the same values that you used in the first call.</p>
20    pub fn client_token(&self) -> ::std::option::Option<&str> {
21        self.client_token.as_deref()
22    }
23    /// <p>This operation is performed asynchronously, and this response parameter indicates the current status.</p>
24    pub fn permission_status(&self) -> ::std::option::Option<&crate::types::PermissionStatus> {
25        self.permission_status.as_ref()
26    }
27}
28impl ::aws_types::request_id::RequestId for DeletePermissionOutput {
29    fn request_id(&self) -> Option<&str> {
30        self._request_id.as_deref()
31    }
32}
33impl DeletePermissionOutput {
34    /// Creates a new builder-style object to manufacture [`DeletePermissionOutput`](crate::operation::delete_permission::DeletePermissionOutput).
35    pub fn builder() -> crate::operation::delete_permission::builders::DeletePermissionOutputBuilder {
36        crate::operation::delete_permission::builders::DeletePermissionOutputBuilder::default()
37    }
38}
39
40/// A builder for [`DeletePermissionOutput`](crate::operation::delete_permission::DeletePermissionOutput).
41#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
42#[non_exhaustive]
43pub struct DeletePermissionOutputBuilder {
44    pub(crate) return_value: ::std::option::Option<bool>,
45    pub(crate) client_token: ::std::option::Option<::std::string::String>,
46    pub(crate) permission_status: ::std::option::Option<crate::types::PermissionStatus>,
47    _request_id: Option<String>,
48}
49impl DeletePermissionOutputBuilder {
50    /// <p>A boolean that indicates whether the delete operations succeeded.</p>
51    pub fn return_value(mut self, input: bool) -> Self {
52        self.return_value = ::std::option::Option::Some(input);
53        self
54    }
55    /// <p>A boolean that indicates whether the delete operations succeeded.</p>
56    pub fn set_return_value(mut self, input: ::std::option::Option<bool>) -> Self {
57        self.return_value = input;
58        self
59    }
60    /// <p>A boolean that indicates whether the delete operations succeeded.</p>
61    pub fn get_return_value(&self) -> &::std::option::Option<bool> {
62        &self.return_value
63    }
64    /// <p>The idempotency identifier associated with this request. If you want to repeat the same operation in an idempotent manner then you must include this value in the <code>clientToken</code> request parameter of that later call. All other parameters must also have the same values that you used in the first call.</p>
65    pub fn client_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
66        self.client_token = ::std::option::Option::Some(input.into());
67        self
68    }
69    /// <p>The idempotency identifier associated with this request. If you want to repeat the same operation in an idempotent manner then you must include this value in the <code>clientToken</code> request parameter of that later call. All other parameters must also have the same values that you used in the first call.</p>
70    pub fn set_client_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
71        self.client_token = input;
72        self
73    }
74    /// <p>The idempotency identifier associated with this request. If you want to repeat the same operation in an idempotent manner then you must include this value in the <code>clientToken</code> request parameter of that later call. All other parameters must also have the same values that you used in the first call.</p>
75    pub fn get_client_token(&self) -> &::std::option::Option<::std::string::String> {
76        &self.client_token
77    }
78    /// <p>This operation is performed asynchronously, and this response parameter indicates the current status.</p>
79    pub fn permission_status(mut self, input: crate::types::PermissionStatus) -> Self {
80        self.permission_status = ::std::option::Option::Some(input);
81        self
82    }
83    /// <p>This operation is performed asynchronously, and this response parameter indicates the current status.</p>
84    pub fn set_permission_status(mut self, input: ::std::option::Option<crate::types::PermissionStatus>) -> Self {
85        self.permission_status = input;
86        self
87    }
88    /// <p>This operation is performed asynchronously, and this response parameter indicates the current status.</p>
89    pub fn get_permission_status(&self) -> &::std::option::Option<crate::types::PermissionStatus> {
90        &self.permission_status
91    }
92    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
93        self._request_id = Some(request_id.into());
94        self
95    }
96
97    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
98        self._request_id = request_id;
99        self
100    }
101    /// Consumes the builder and constructs a [`DeletePermissionOutput`](crate::operation::delete_permission::DeletePermissionOutput).
102    pub fn build(self) -> crate::operation::delete_permission::DeletePermissionOutput {
103        crate::operation::delete_permission::DeletePermissionOutput {
104            return_value: self.return_value,
105            client_token: self.client_token,
106            permission_status: self.permission_status,
107            _request_id: self._request_id,
108        }
109    }
110}