Struct aws_sdk_ec2::model::S3Storage
source · #[non_exhaustive]pub struct S3Storage { /* private fields */ }
Expand description
Describes the storage parameters for Amazon S3 and Amazon S3 buckets for an instance store-backed AMI.
Implementations§
source§impl S3Storage
impl S3Storage
sourcepub fn aws_access_key_id(&self) -> Option<&str>
pub fn aws_access_key_id(&self) -> Option<&str>
The access key ID of the owner of the bucket. Before you specify a value for your access key ID, review and follow the guidance in Best Practices for Managing Amazon Web Services Access Keys.
sourcepub fn bucket(&self) -> Option<&str>
pub fn bucket(&self) -> Option<&str>
The bucket in which to store the AMI. You can specify a bucket that you already own or a new bucket that Amazon EC2 creates on your behalf. If you specify a bucket that belongs to someone else, Amazon EC2 returns an error.
sourcepub fn upload_policy(&self) -> Option<&Blob>
pub fn upload_policy(&self) -> Option<&Blob>
An Amazon S3 upload policy that gives Amazon EC2 permission to upload items into Amazon S3 on your behalf.
sourcepub fn upload_policy_signature(&self) -> Option<&str>
pub fn upload_policy_signature(&self) -> Option<&str>
The signature of the JSON document.
source§impl S3Storage
impl S3Storage
sourcepub fn builder() -> Builder
pub fn builder() -> Builder
Creates a new builder-style object to manufacture S3Storage
.
Examples found in repository?
src/xml_deser.rs (line 56446)
56442 56443 56444 56445 56446 56447 56448 56449 56450 56451 56452 56453 56454 56455 56456 56457 56458 56459 56460 56461 56462 56463 56464 56465 56466 56467 56468 56469 56470 56471 56472 56473 56474 56475 56476 56477 56478 56479 56480 56481 56482 56483 56484 56485 56486 56487 56488 56489 56490 56491 56492 56493 56494 56495 56496 56497 56498 56499 56500 56501 56502 56503 56504 56505 56506 56507 56508 56509 56510 56511 56512 56513 56514 56515 56516 56517 56518
pub fn deser_structure_crate_model_s3_storage(
decoder: &mut aws_smithy_xml::decode::ScopedDecoder,
) -> Result<crate::model::S3Storage, aws_smithy_xml::decode::XmlDecodeError> {
#[allow(unused_mut)]
let mut builder = crate::model::S3Storage::builder();
while let Some(mut tag) = decoder.next_tag() {
match tag.start_el() {
s if s.matches("AWSAccessKeyId") /* AWSAccessKeyId com.amazonaws.ec2#S3Storage$AWSAccessKeyId */ => {
let var_2742 =
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_aws_access_key_id(var_2742);
}
,
s if s.matches("bucket") /* Bucket com.amazonaws.ec2#S3Storage$Bucket */ => {
let var_2743 =
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_bucket(var_2743);
}
,
s if s.matches("prefix") /* Prefix com.amazonaws.ec2#S3Storage$Prefix */ => {
let var_2744 =
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_2744);
}
,
s if s.matches("uploadPolicy") /* UploadPolicy com.amazonaws.ec2#S3Storage$UploadPolicy */ => {
let var_2745 =
Some(
aws_smithy_types::base64::decode(
aws_smithy_xml::decode::try_data(&mut tag)?.as_ref()
)
.map_err(|err|aws_smithy_xml::decode::XmlDecodeError::custom(format!("invalid base64: {:?}", err))).map(aws_smithy_types::Blob::new)
?
)
;
builder = builder.set_upload_policy(var_2745);
}
,
s if s.matches("uploadPolicySignature") /* UploadPolicySignature com.amazonaws.ec2#S3Storage$UploadPolicySignature */ => {
let var_2746 =
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_upload_policy_signature(var_2746);
}
,
_ => {}
}
}
Ok(builder.build())
}