pub struct Builder { /* private fields */ }Expand description
A builder for StopContinuousExportOutput.
Implementations§
source§impl Builder
impl Builder
sourcepub fn start_time(self, input: DateTime) -> Self
pub fn start_time(self, input: DateTime) -> Self
Timestamp that represents when this continuous export started collecting data.
sourcepub fn set_start_time(self, input: Option<DateTime>) -> Self
pub fn set_start_time(self, input: Option<DateTime>) -> Self
Timestamp that represents when this continuous export started collecting data.
Examples found in repository?
src/json_deser.rs (lines 1418-1423)
1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454
pub(crate) fn deser_operation_crate_operation_stop_continuous_export(
value: &[u8],
mut builder: crate::output::stop_continuous_export_output::Builder,
) -> Result<
crate::output::stop_continuous_export_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() {
"startTime" => {
builder = builder.set_start_time(
aws_smithy_json::deserialize::token::expect_timestamp_or_null(
tokens.next(),
aws_smithy_types::date_time::Format::EpochSeconds,
)?,
);
}
"stopTime" => {
builder = builder.set_stop_time(
aws_smithy_json::deserialize::token::expect_timestamp_or_null(
tokens.next(),
aws_smithy_types::date_time::Format::EpochSeconds,
)?,
);
}
_ => 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 stop_time(self, input: DateTime) -> Self
pub fn stop_time(self, input: DateTime) -> Self
Timestamp that represents when this continuous export was stopped.
sourcepub fn set_stop_time(self, input: Option<DateTime>) -> Self
pub fn set_stop_time(self, input: Option<DateTime>) -> Self
Timestamp that represents when this continuous export was stopped.
Examples found in repository?
src/json_deser.rs (lines 1426-1431)
1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454
pub(crate) fn deser_operation_crate_operation_stop_continuous_export(
value: &[u8],
mut builder: crate::output::stop_continuous_export_output::Builder,
) -> Result<
crate::output::stop_continuous_export_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() {
"startTime" => {
builder = builder.set_start_time(
aws_smithy_json::deserialize::token::expect_timestamp_or_null(
tokens.next(),
aws_smithy_types::date_time::Format::EpochSeconds,
)?,
);
}
"stopTime" => {
builder = builder.set_stop_time(
aws_smithy_json::deserialize::token::expect_timestamp_or_null(
tokens.next(),
aws_smithy_types::date_time::Format::EpochSeconds,
)?,
);
}
_ => 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 build(self) -> StopContinuousExportOutput
pub fn build(self) -> StopContinuousExportOutput
Consumes the builder and constructs a StopContinuousExportOutput.
Examples found in repository?
src/operation_deser.rs (line 3191)
3176 3177 3178 3179 3180 3181 3182 3183 3184 3185 3186 3187 3188 3189 3190 3191 3192 3193
pub fn parse_stop_continuous_export_response(
response: &http::Response<bytes::Bytes>,
) -> std::result::Result<
crate::output::StopContinuousExportOutput,
crate::error::StopContinuousExportError,
> {
Ok({
#[allow(unused_mut)]
let mut output = crate::output::stop_continuous_export_output::Builder::default();
let _ = response;
output = crate::json_deser::deser_operation_crate_operation_stop_continuous_export(
response.body().as_ref(),
output,
)
.map_err(crate::error::StopContinuousExportError::unhandled)?;
output.build()
})
}