aws_sdk_paymentcryptography/operation/delete_key/
builders.rs1pub use crate::operation::delete_key::_delete_key_output::DeleteKeyOutputBuilder;
3
4pub use crate::operation::delete_key::_delete_key_input::DeleteKeyInputBuilder;
5
6impl crate::operation::delete_key::builders::DeleteKeyInputBuilder {
7 pub async fn send_with(
9 self,
10 client: &crate::Client,
11 ) -> ::std::result::Result<
12 crate::operation::delete_key::DeleteKeyOutput,
13 ::aws_smithy_runtime_api::client::result::SdkError<
14 crate::operation::delete_key::DeleteKeyError,
15 ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
16 >,
17 > {
18 let mut fluent_builder = client.delete_key();
19 fluent_builder.inner = self;
20 fluent_builder.send().await
21 }
22}
23#[derive(::std::clone::Clone, ::std::fmt::Debug)]
39pub struct DeleteKeyFluentBuilder {
40 handle: ::std::sync::Arc<crate::client::Handle>,
41 inner: crate::operation::delete_key::builders::DeleteKeyInputBuilder,
42 config_override: ::std::option::Option<crate::config::Builder>,
43}
44impl crate::client::customize::internal::CustomizableSend<crate::operation::delete_key::DeleteKeyOutput, crate::operation::delete_key::DeleteKeyError>
45 for DeleteKeyFluentBuilder
46{
47 fn send(
48 self,
49 config_override: crate::config::Builder,
50 ) -> crate::client::customize::internal::BoxFuture<
51 crate::client::customize::internal::SendResult<crate::operation::delete_key::DeleteKeyOutput, crate::operation::delete_key::DeleteKeyError>,
52 > {
53 ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
54 }
55}
56impl DeleteKeyFluentBuilder {
57 pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
59 Self {
60 handle,
61 inner: ::std::default::Default::default(),
62 config_override: ::std::option::Option::None,
63 }
64 }
65 pub fn as_input(&self) -> &crate::operation::delete_key::builders::DeleteKeyInputBuilder {
67 &self.inner
68 }
69 pub async fn send(
78 self,
79 ) -> ::std::result::Result<
80 crate::operation::delete_key::DeleteKeyOutput,
81 ::aws_smithy_runtime_api::client::result::SdkError<
82 crate::operation::delete_key::DeleteKeyError,
83 ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
84 >,
85 > {
86 let input = self
87 .inner
88 .build()
89 .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
90 let runtime_plugins = crate::operation::delete_key::DeleteKey::operation_runtime_plugins(
91 self.handle.runtime_plugins.clone(),
92 &self.handle.conf,
93 self.config_override,
94 );
95 crate::operation::delete_key::DeleteKey::orchestrate(&runtime_plugins, input).await
96 }
97
98 pub fn customize(
100 self,
101 ) -> crate::client::customize::CustomizableOperation<
102 crate::operation::delete_key::DeleteKeyOutput,
103 crate::operation::delete_key::DeleteKeyError,
104 Self,
105 > {
106 crate::client::customize::CustomizableOperation::new(self)
107 }
108 pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
109 self.set_config_override(::std::option::Option::Some(config_override.into()));
110 self
111 }
112
113 pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
114 self.config_override = config_override;
115 self
116 }
117 pub fn key_identifier(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
119 self.inner = self.inner.key_identifier(input.into());
120 self
121 }
122 pub fn set_key_identifier(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
124 self.inner = self.inner.set_key_identifier(input);
125 self
126 }
127 pub fn get_key_identifier(&self) -> &::std::option::Option<::std::string::String> {
129 self.inner.get_key_identifier()
130 }
131 pub fn delete_key_in_days(mut self, input: i32) -> Self {
133 self.inner = self.inner.delete_key_in_days(input);
134 self
135 }
136 pub fn set_delete_key_in_days(mut self, input: ::std::option::Option<i32>) -> Self {
138 self.inner = self.inner.set_delete_key_in_days(input);
139 self
140 }
141 pub fn get_delete_key_in_days(&self) -> &::std::option::Option<i32> {
143 self.inner.get_delete_key_in_days()
144 }
145}