Struct aws_sdk_quicksight::operation::DeleteThemeAlias
source · pub struct DeleteThemeAlias { /* private fields */ }Expand description
Operation shape for DeleteThemeAlias.
This is usually constructed for you using the the fluent builder returned by
delete_theme_alias.
See crate::client::fluent_builders::DeleteThemeAlias for more details about the operation.
Implementations§
source§impl DeleteThemeAlias
impl DeleteThemeAlias
sourcepub fn builder() -> Builder
pub fn builder() -> Builder
Creates a new builder-style object to manufacture DeleteThemeAliasInput.
sourcepub fn new() -> Self
pub fn new() -> Self
Creates a new DeleteThemeAlias operation.
Examples found in repository?
src/input.rs (line 8258)
8118 8119 8120 8121 8122 8123 8124 8125 8126 8127 8128 8129 8130 8131 8132 8133 8134 8135 8136 8137 8138 8139 8140 8141 8142 8143 8144 8145 8146 8147 8148 8149 8150 8151 8152 8153 8154 8155 8156 8157 8158 8159 8160 8161 8162 8163 8164 8165 8166 8167 8168 8169 8170 8171 8172 8173 8174 8175 8176 8177 8178 8179 8180 8181 8182 8183 8184 8185 8186 8187 8188 8189 8190 8191 8192 8193 8194 8195 8196 8197 8198 8199 8200 8201 8202 8203 8204 8205 8206 8207 8208 8209 8210 8211 8212 8213 8214 8215 8216 8217 8218 8219 8220 8221 8222 8223 8224 8225 8226 8227 8228 8229 8230 8231 8232 8233 8234 8235 8236 8237 8238 8239 8240 8241 8242 8243 8244 8245 8246 8247 8248 8249 8250 8251 8252 8253 8254 8255 8256 8257 8258 8259 8260 8261 8262 8263 8264 8265 8266
pub async fn make_operation(
&self,
_config: &crate::config::Config,
) -> std::result::Result<
aws_smithy_http::operation::Operation<
crate::operation::DeleteThemeAlias,
aws_http::retry::AwsResponseRetryClassifier,
>,
aws_smithy_http::operation::error::BuildError,
> {
let mut request = {
fn uri_base(
_input: &crate::input::DeleteThemeAliasInput,
output: &mut String,
) -> Result<(), aws_smithy_http::operation::error::BuildError> {
let input_80 = &_input.aws_account_id;
let input_80 = input_80.as_ref().ok_or_else(|| {
aws_smithy_http::operation::error::BuildError::missing_field(
"aws_account_id",
"cannot be empty or unset",
)
})?;
let aws_account_id = aws_smithy_http::label::fmt_string(
input_80,
aws_smithy_http::label::EncodingStrategy::Default,
);
if aws_account_id.is_empty() {
return Err(
aws_smithy_http::operation::error::BuildError::missing_field(
"aws_account_id",
"cannot be empty or unset",
),
);
}
let input_81 = &_input.theme_id;
let input_81 = input_81.as_ref().ok_or_else(|| {
aws_smithy_http::operation::error::BuildError::missing_field(
"theme_id",
"cannot be empty or unset",
)
})?;
let theme_id = aws_smithy_http::label::fmt_string(
input_81,
aws_smithy_http::label::EncodingStrategy::Default,
);
if theme_id.is_empty() {
return Err(
aws_smithy_http::operation::error::BuildError::missing_field(
"theme_id",
"cannot be empty or unset",
),
);
}
let input_82 = &_input.alias_name;
let input_82 = input_82.as_ref().ok_or_else(|| {
aws_smithy_http::operation::error::BuildError::missing_field(
"alias_name",
"cannot be empty or unset",
)
})?;
let alias_name = aws_smithy_http::label::fmt_string(
input_82,
aws_smithy_http::label::EncodingStrategy::Default,
);
if alias_name.is_empty() {
return Err(
aws_smithy_http::operation::error::BuildError::missing_field(
"alias_name",
"cannot be empty or unset",
),
);
}
write!(
output,
"/accounts/{AwsAccountId}/themes/{ThemeId}/aliases/{AliasName}",
AwsAccountId = aws_account_id,
ThemeId = theme_id,
AliasName = alias_name
)
.expect("formatting should succeed");
Ok(())
}
#[allow(clippy::unnecessary_wraps)]
fn update_http_builder(
input: &crate::input::DeleteThemeAliasInput,
builder: http::request::Builder,
) -> std::result::Result<
http::request::Builder,
aws_smithy_http::operation::error::BuildError,
> {
let mut uri = String::new();
uri_base(input, &mut uri)?;
Ok(builder.method("DELETE").uri(uri))
}
let mut builder = update_http_builder(&self, http::request::Builder::new())?;
builder
};
let mut properties = aws_smithy_http::property_bag::SharedPropertyBag::new();
#[allow(clippy::useless_conversion)]
let body = aws_smithy_http::body::SdkBody::from("");
let request = request.body(body).expect("should be valid request");
let mut request = aws_smithy_http::operation::Request::from_parts(request, properties);
request
.properties_mut()
.insert(aws_smithy_http::http_versions::DEFAULT_HTTP_VERSION_LIST.clone());
let mut user_agent = aws_http::user_agent::AwsUserAgent::new_from_environment(
aws_types::os_shim_internal::Env::real(),
crate::API_METADATA.clone(),
);
if let Some(app_name) = _config.app_name() {
user_agent = user_agent.with_app_name(app_name.clone());
}
request.properties_mut().insert(user_agent);
let mut signing_config = aws_sig_auth::signer::OperationSigningConfig::default_config();
request.properties_mut().insert(signing_config);
request
.properties_mut()
.insert(aws_types::SigningService::from_static(
_config.signing_service(),
));
if let Some(region) = &_config.region {
request
.properties_mut()
.insert(aws_types::region::SigningRegion::from(region.clone()));
}
let endpoint_params = aws_endpoint::Params::new(_config.region.clone());
request
.properties_mut()
.insert::<aws_smithy_http::endpoint::Result>(
_config.endpoint_resolver.resolve_endpoint(&endpoint_params),
);
if let Some(region) = &_config.region {
request.properties_mut().insert(region.clone());
}
aws_http::auth::set_provider(
&mut request.properties_mut(),
_config.credentials_provider.clone(),
);
let op = aws_smithy_http::operation::Operation::new(
request,
crate::operation::DeleteThemeAlias::new(),
)
.with_metadata(aws_smithy_http::operation::Metadata::new(
"DeleteThemeAlias",
"quicksight",
));
let op = op.with_retry_classifier(aws_http::retry::AwsResponseRetryClassifier::new());
Ok(op)
}Trait Implementations§
source§impl Clone for DeleteThemeAlias
impl Clone for DeleteThemeAlias
source§fn clone(&self) -> DeleteThemeAlias
fn clone(&self) -> DeleteThemeAlias
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moresource§impl Debug for DeleteThemeAlias
impl Debug for DeleteThemeAlias
source§impl Default for DeleteThemeAlias
impl Default for DeleteThemeAlias
source§fn default() -> DeleteThemeAlias
fn default() -> DeleteThemeAlias
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl RefUnwindSafe for DeleteThemeAlias
impl Send for DeleteThemeAlias
impl Sync for DeleteThemeAlias
impl Unpin for DeleteThemeAlias
impl UnwindSafe for DeleteThemeAlias
Blanket Implementations§
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> ParseHttpResponse for Twhere
T: ParseStrictResponse,
impl<T> ParseHttpResponse for Twhere
T: ParseStrictResponse,
§type Output = <T as ParseStrictResponse>::Output
type Output = <T as ParseStrictResponse>::Output
Output type of the HttpResponse. Read more
source§fn parse_unloaded(
&self,
_response: &mut Response
) -> Option<<T as ParseHttpResponse>::Output>
fn parse_unloaded(
&self,
_response: &mut Response
) -> Option<<T as ParseHttpResponse>::Output>
Parse an HTTP request without reading the body. If the body must be provided to proceed,
return
None Read moresource§fn parse_loaded(
&self,
response: &Response<Bytes>
) -> <T as ParseHttpResponse>::Output
fn parse_loaded(
&self,
response: &Response<Bytes>
) -> <T as ParseHttpResponse>::Output
Parse an HTTP request from a fully loaded body. This is for standard request/response style
APIs like AwsJson 1.0/1.1 and the error path of most streaming APIs Read more