Struct aws_sdk_quicksight::output::update_user_output::Builder
source · pub struct Builder { /* private fields */ }Expand description
A builder for UpdateUserOutput.
Implementations§
source§impl Builder
impl Builder
sourcepub fn set_user(self, input: Option<User>) -> Self
pub fn set_user(self, input: Option<User>) -> Self
The Amazon QuickSight user.
Examples found in repository?
src/json_deser.rs (line 8911)
8883 8884 8885 8886 8887 8888 8889 8890 8891 8892 8893 8894 8895 8896 8897 8898 8899 8900 8901 8902 8903 8904 8905 8906 8907 8908 8909 8910 8911 8912 8913 8914 8915 8916 8917 8918 8919 8920 8921 8922 8923 8924 8925 8926 8927 8928 8929 8930 8931 8932 8933 8934
pub(crate) fn deser_operation_crate_operation_update_user(
value: &[u8],
mut builder: crate::output::update_user_output::Builder,
) -> Result<
crate::output::update_user_output::Builder,
aws_smithy_json::deserialize::error::DeserializeError,
> {
let mut tokens_owned =
aws_smithy_json::deserialize::json_token_iter(crate::json_deser::or_empty_doc(value))
.peekable();
let tokens = &mut tokens_owned;
aws_smithy_json::deserialize::token::expect_start_object(tokens.next())?;
loop {
match tokens.next().transpose()? {
Some(aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
Some(aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => {
match key.to_unescaped()?.as_ref() {
"RequestId" => {
builder = builder.set_request_id(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| s.to_unescaped().map(|u| u.into_owned()))
.transpose()?,
);
}
"User" => {
builder = builder
.set_user(crate::json_deser::deser_structure_crate_model_user(tokens)?);
}
_ => aws_smithy_json::deserialize::token::skip_value(tokens)?,
}
}
other => {
return Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
"expected object key or end object, found: {:?}",
other
)),
)
}
}
}
if tokens.next().is_some() {
return Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(
"found more JSON tokens after completing parsing",
),
);
}
Ok(builder)
}sourcepub fn request_id(self, input: impl Into<String>) -> Self
pub fn request_id(self, input: impl Into<String>) -> Self
The Amazon Web Services request ID for this operation.
sourcepub fn set_request_id(self, input: Option<String>) -> Self
pub fn set_request_id(self, input: Option<String>) -> Self
The Amazon Web Services request ID for this operation.
Examples found in repository?
src/json_deser.rs (lines 8901-8907)
8883 8884 8885 8886 8887 8888 8889 8890 8891 8892 8893 8894 8895 8896 8897 8898 8899 8900 8901 8902 8903 8904 8905 8906 8907 8908 8909 8910 8911 8912 8913 8914 8915 8916 8917 8918 8919 8920 8921 8922 8923 8924 8925 8926 8927 8928 8929 8930 8931 8932 8933 8934
pub(crate) fn deser_operation_crate_operation_update_user(
value: &[u8],
mut builder: crate::output::update_user_output::Builder,
) -> Result<
crate::output::update_user_output::Builder,
aws_smithy_json::deserialize::error::DeserializeError,
> {
let mut tokens_owned =
aws_smithy_json::deserialize::json_token_iter(crate::json_deser::or_empty_doc(value))
.peekable();
let tokens = &mut tokens_owned;
aws_smithy_json::deserialize::token::expect_start_object(tokens.next())?;
loop {
match tokens.next().transpose()? {
Some(aws_smithy_json::deserialize::Token::EndObject { .. }) => break,
Some(aws_smithy_json::deserialize::Token::ObjectKey { key, .. }) => {
match key.to_unescaped()?.as_ref() {
"RequestId" => {
builder = builder.set_request_id(
aws_smithy_json::deserialize::token::expect_string_or_null(
tokens.next(),
)?
.map(|s| s.to_unescaped().map(|u| u.into_owned()))
.transpose()?,
);
}
"User" => {
builder = builder
.set_user(crate::json_deser::deser_structure_crate_model_user(tokens)?);
}
_ => aws_smithy_json::deserialize::token::skip_value(tokens)?,
}
}
other => {
return Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(format!(
"expected object key or end object, found: {:?}",
other
)),
)
}
}
}
if tokens.next().is_some() {
return Err(
aws_smithy_json::deserialize::error::DeserializeError::custom(
"found more JSON tokens after completing parsing",
),
);
}
Ok(builder)
}sourcepub fn set_status(self, input: Option<i32>) -> Self
pub fn set_status(self, input: Option<i32>) -> Self
The HTTP status of the request.
Examples found in repository?
src/operation_deser.rs (line 18557)
18545 18546 18547 18548 18549 18550 18551 18552 18553 18554 18555 18556 18557 18558 18559 18560
pub fn parse_update_user_response(
response: &http::Response<bytes::Bytes>,
) -> std::result::Result<crate::output::UpdateUserOutput, crate::error::UpdateUserError> {
Ok({
#[allow(unused_mut)]
let mut output = crate::output::update_user_output::Builder::default();
let _ = response;
output = crate::json_deser::deser_operation_crate_operation_update_user(
response.body().as_ref(),
output,
)
.map_err(crate::error::UpdateUserError::unhandled)?;
output = output.set_status(Some(response.status().as_u16() as _));
output.build()
})
}sourcepub fn build(self) -> UpdateUserOutput
pub fn build(self) -> UpdateUserOutput
Consumes the builder and constructs a UpdateUserOutput.
Examples found in repository?
src/operation_deser.rs (line 18558)
18545 18546 18547 18548 18549 18550 18551 18552 18553 18554 18555 18556 18557 18558 18559 18560
pub fn parse_update_user_response(
response: &http::Response<bytes::Bytes>,
) -> std::result::Result<crate::output::UpdateUserOutput, crate::error::UpdateUserError> {
Ok({
#[allow(unused_mut)]
let mut output = crate::output::update_user_output::Builder::default();
let _ = response;
output = crate::json_deser::deser_operation_crate_operation_update_user(
response.body().as_ref(),
output,
)
.map_err(crate::error::UpdateUserError::unhandled)?;
output = output.set_status(Some(response.status().as_u16() as _));
output.build()
})
}