aws_sdk_ssoadmin/operation/attach_customer_managed_policy_reference_to_permission_set/
builders.rs1pub use crate::operation::attach_customer_managed_policy_reference_to_permission_set::_attach_customer_managed_policy_reference_to_permission_set_input::AttachCustomerManagedPolicyReferenceToPermissionSetInputBuilder;
3
4pub use crate::operation::attach_customer_managed_policy_reference_to_permission_set::_attach_customer_managed_policy_reference_to_permission_set_output::AttachCustomerManagedPolicyReferenceToPermissionSetOutputBuilder;
5
6impl crate::operation::attach_customer_managed_policy_reference_to_permission_set::builders::AttachCustomerManagedPolicyReferenceToPermissionSetInputBuilder {
7 pub async fn send_with(self, client: &crate::Client) -> ::std::result::Result<
9 crate::operation::attach_customer_managed_policy_reference_to_permission_set::AttachCustomerManagedPolicyReferenceToPermissionSetOutput,
10 ::aws_smithy_runtime_api::client::result::SdkError<
11 crate::operation::attach_customer_managed_policy_reference_to_permission_set::AttachCustomerManagedPolicyReferenceToPermissionSetError,
12 ::aws_smithy_runtime_api::client::orchestrator::HttpResponse
13 >
14 > {
15 let mut fluent_builder = client.attach_customer_managed_policy_reference_to_permission_set();
16 fluent_builder.inner = self;
17 fluent_builder.send().await
18 }
19 }
20#[derive(::std::clone::Clone, ::std::fmt::Debug)]
24pub struct AttachCustomerManagedPolicyReferenceToPermissionSetFluentBuilder {
25 handle: ::std::sync::Arc<crate::client::Handle>,
26 inner: crate::operation::attach_customer_managed_policy_reference_to_permission_set::builders::AttachCustomerManagedPolicyReferenceToPermissionSetInputBuilder,
27config_override: ::std::option::Option<crate::config::Builder>,
28 }
29impl
30 crate::client::customize::internal::CustomizableSend<
31 crate::operation::attach_customer_managed_policy_reference_to_permission_set::AttachCustomerManagedPolicyReferenceToPermissionSetOutput,
32 crate::operation::attach_customer_managed_policy_reference_to_permission_set::AttachCustomerManagedPolicyReferenceToPermissionSetError,
33 > for AttachCustomerManagedPolicyReferenceToPermissionSetFluentBuilder
34{
35 fn send(
36 self,
37 config_override: crate::config::Builder,
38 ) -> crate::client::customize::internal::BoxFuture<
39 crate::client::customize::internal::SendResult<
40 crate::operation::attach_customer_managed_policy_reference_to_permission_set::AttachCustomerManagedPolicyReferenceToPermissionSetOutput,
41 crate::operation::attach_customer_managed_policy_reference_to_permission_set::AttachCustomerManagedPolicyReferenceToPermissionSetError,
42 >,
43 > {
44 ::std::boxed::Box::pin(async move { self.config_override(config_override).send().await })
45 }
46}
47impl AttachCustomerManagedPolicyReferenceToPermissionSetFluentBuilder {
48 pub(crate) fn new(handle: ::std::sync::Arc<crate::client::Handle>) -> Self {
50 Self {
51 handle,
52 inner: ::std::default::Default::default(),
53 config_override: ::std::option::Option::None,
54 }
55 }
56 pub fn as_input(&self) -> &crate::operation::attach_customer_managed_policy_reference_to_permission_set::builders::AttachCustomerManagedPolicyReferenceToPermissionSetInputBuilder{
58 &self.inner
59 }
60 pub async fn send(
69 self,
70 ) -> ::std::result::Result<
71 crate::operation::attach_customer_managed_policy_reference_to_permission_set::AttachCustomerManagedPolicyReferenceToPermissionSetOutput,
72 ::aws_smithy_runtime_api::client::result::SdkError<
73 crate::operation::attach_customer_managed_policy_reference_to_permission_set::AttachCustomerManagedPolicyReferenceToPermissionSetError,
74 ::aws_smithy_runtime_api::client::orchestrator::HttpResponse,
75 >,
76 > {
77 let input = self
78 .inner
79 .build()
80 .map_err(::aws_smithy_runtime_api::client::result::SdkError::construction_failure)?;
81 let runtime_plugins = crate::operation::attach_customer_managed_policy_reference_to_permission_set::AttachCustomerManagedPolicyReferenceToPermissionSet::operation_runtime_plugins(
82 self.handle.runtime_plugins.clone(),
83 &self.handle.conf,
84 self.config_override,
85 );
86 crate::operation::attach_customer_managed_policy_reference_to_permission_set::AttachCustomerManagedPolicyReferenceToPermissionSet::orchestrate(&runtime_plugins, input).await
87 }
88
89 pub fn customize(
91 self,
92 ) -> crate::client::customize::CustomizableOperation<
93 crate::operation::attach_customer_managed_policy_reference_to_permission_set::AttachCustomerManagedPolicyReferenceToPermissionSetOutput,
94 crate::operation::attach_customer_managed_policy_reference_to_permission_set::AttachCustomerManagedPolicyReferenceToPermissionSetError,
95 Self,
96 > {
97 crate::client::customize::CustomizableOperation::new(self)
98 }
99 pub(crate) fn config_override(mut self, config_override: impl ::std::convert::Into<crate::config::Builder>) -> Self {
100 self.set_config_override(::std::option::Option::Some(config_override.into()));
101 self
102 }
103
104 pub(crate) fn set_config_override(&mut self, config_override: ::std::option::Option<crate::config::Builder>) -> &mut Self {
105 self.config_override = config_override;
106 self
107 }
108 pub fn instance_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
110 self.inner = self.inner.instance_arn(input.into());
111 self
112 }
113 pub fn set_instance_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
115 self.inner = self.inner.set_instance_arn(input);
116 self
117 }
118 pub fn get_instance_arn(&self) -> &::std::option::Option<::std::string::String> {
120 self.inner.get_instance_arn()
121 }
122 pub fn permission_set_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
124 self.inner = self.inner.permission_set_arn(input.into());
125 self
126 }
127 pub fn set_permission_set_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
129 self.inner = self.inner.set_permission_set_arn(input);
130 self
131 }
132 pub fn get_permission_set_arn(&self) -> &::std::option::Option<::std::string::String> {
134 self.inner.get_permission_set_arn()
135 }
136 pub fn customer_managed_policy_reference(mut self, input: crate::types::CustomerManagedPolicyReference) -> Self {
138 self.inner = self.inner.customer_managed_policy_reference(input);
139 self
140 }
141 pub fn set_customer_managed_policy_reference(mut self, input: ::std::option::Option<crate::types::CustomerManagedPolicyReference>) -> Self {
143 self.inner = self.inner.set_customer_managed_policy_reference(input);
144 self
145 }
146 pub fn get_customer_managed_policy_reference(&self) -> &::std::option::Option<crate::types::CustomerManagedPolicyReference> {
148 self.inner.get_customer_managed_policy_reference()
149 }
150}