pub struct Builder { /* private fields */ }
Expand description
A builder for GetNetworkSettingsOutput
.
Implementations§
source§impl Builder
impl Builder
sourcepub fn network_settings(self, input: NetworkSettings) -> Self
pub fn network_settings(self, input: NetworkSettings) -> Self
The network settings.
sourcepub fn set_network_settings(self, input: Option<NetworkSettings>) -> Self
pub fn set_network_settings(self, input: Option<NetworkSettings>) -> Self
The network settings.
Examples found in repository?
src/json_deser.rs (lines 1124-1128)
1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151
pub(crate) fn deser_operation_crate_operation_get_network_settings(
value: &[u8],
mut builder: crate::output::get_network_settings_output::Builder,
) -> Result<
crate::output::get_network_settings_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() {
"networkSettings" => {
builder = builder.set_network_settings(
crate::json_deser::deser_structure_crate_model_network_settings(
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 build(self) -> GetNetworkSettingsOutput
pub fn build(self) -> GetNetworkSettingsOutput
Consumes the builder and constructs a GetNetworkSettingsOutput
.
Examples found in repository?
src/operation_deser.rs (line 3259)
3244 3245 3246 3247 3248 3249 3250 3251 3252 3253 3254 3255 3256 3257 3258 3259 3260 3261
pub fn parse_get_network_settings_response(
response: &http::Response<bytes::Bytes>,
) -> std::result::Result<
crate::output::GetNetworkSettingsOutput,
crate::error::GetNetworkSettingsError,
> {
Ok({
#[allow(unused_mut)]
let mut output = crate::output::get_network_settings_output::Builder::default();
let _ = response;
output = crate::json_deser::deser_operation_crate_operation_get_network_settings(
response.body().as_ref(),
output,
)
.map_err(crate::error::GetNetworkSettingsError::unhandled)?;
output.build()
})
}