Struct aws_sdk_s3::model::common_prefix::Builder
source · pub struct Builder { /* private fields */ }
Expand description
A builder for CommonPrefix
.
Implementations§
source§impl Builder
impl Builder
sourcepub fn prefix(self, input: impl Into<String>) -> Self
pub fn prefix(self, input: impl Into<String>) -> Self
Container for the specified common prefix.
sourcepub fn set_prefix(self, input: Option<String>) -> Self
pub fn set_prefix(self, input: Option<String>) -> Self
Container for the specified common prefix.
Examples found in repository?
src/xml_deser.rs (line 4185)
4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190 4191 4192
pub fn deser_structure_crate_model_common_prefix(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::CommonPrefix, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::CommonPrefix::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("Prefix") /* Prefix com.amazonaws.s3#CommonPrefix$Prefix */ => {
let var_231 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_prefix(var_231);
}
,
_ => {}
}
}
Ok(builder.build())
}
sourcepub fn build(self) -> CommonPrefix
pub fn build(self) -> CommonPrefix
Consumes the builder and constructs a CommonPrefix
.
Examples found in repository?
src/xml_deser.rs (line 4191)
4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190 4191 4192
pub fn deser_structure_crate_model_common_prefix(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::CommonPrefix, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::CommonPrefix::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("Prefix") /* Prefix com.amazonaws.s3#CommonPrefix$Prefix */ => {
let var_231 =
Some(
Result::<std::string::String, aws_smithy_xml::decode::XmlDecodeError>::Ok(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
.into()
)
?
)
;
builder = builder.set_prefix(var_231);
}
,
_ => {}
}
}
Ok(builder.build())
}