Struct aws_sdk_cloudfront::output::get_public_key_output::Builder
source · pub struct Builder { /* private fields */ }
Expand description
A builder for GetPublicKeyOutput
.
Implementations§
source§impl Builder
impl Builder
sourcepub fn public_key(self, input: PublicKey) -> Self
pub fn public_key(self, input: PublicKey) -> Self
The public key.
sourcepub fn set_public_key(self, input: Option<PublicKey>) -> Self
pub fn set_public_key(self, input: Option<PublicKey>) -> Self
The public key.
Examples found in repository?
src/operation_deser.rs (lines 7767-7771)
7752 7753 7754 7755 7756 7757 7758 7759 7760 7761 7762 7763 7764 7765 7766 7767 7768 7769 7770 7771 7772 7773 7774
pub fn parse_get_public_key_response(
response: &http::Response<bytes::Bytes>,
) -> std::result::Result<crate::output::GetPublicKeyOutput, crate::error::GetPublicKeyError> {
Ok({
#[allow(unused_mut)]
let mut output = crate::output::get_public_key_output::Builder::default();
let _ = response;
output = output.set_e_tag(
crate::http_serde::deser_header_get_public_key_get_public_key_output_e_tag(
response.headers(),
)
.map_err(|_| {
crate::error::GetPublicKeyError::unhandled("Failed to parse ETag from header `ETag")
})?,
);
output = output.set_public_key(
crate::http_serde::deser_payload_get_public_key_get_public_key_output_public_key(
response.body().as_ref(),
)?,
);
output.build()
})
}
sourcepub fn e_tag(self, input: impl Into<String>) -> Self
pub fn e_tag(self, input: impl Into<String>) -> Self
The identifier for this version of the public key.
sourcepub fn set_e_tag(self, input: Option<String>) -> Self
pub fn set_e_tag(self, input: Option<String>) -> Self
The identifier for this version of the public key.
Examples found in repository?
src/operation_deser.rs (lines 7759-7766)
7752 7753 7754 7755 7756 7757 7758 7759 7760 7761 7762 7763 7764 7765 7766 7767 7768 7769 7770 7771 7772 7773 7774
pub fn parse_get_public_key_response(
response: &http::Response<bytes::Bytes>,
) -> std::result::Result<crate::output::GetPublicKeyOutput, crate::error::GetPublicKeyError> {
Ok({
#[allow(unused_mut)]
let mut output = crate::output::get_public_key_output::Builder::default();
let _ = response;
output = output.set_e_tag(
crate::http_serde::deser_header_get_public_key_get_public_key_output_e_tag(
response.headers(),
)
.map_err(|_| {
crate::error::GetPublicKeyError::unhandled("Failed to parse ETag from header `ETag")
})?,
);
output = output.set_public_key(
crate::http_serde::deser_payload_get_public_key_get_public_key_output_public_key(
response.body().as_ref(),
)?,
);
output.build()
})
}
sourcepub fn build(self) -> GetPublicKeyOutput
pub fn build(self) -> GetPublicKeyOutput
Consumes the builder and constructs a GetPublicKeyOutput
.
Examples found in repository?
src/operation_deser.rs (line 7772)
7752 7753 7754 7755 7756 7757 7758 7759 7760 7761 7762 7763 7764 7765 7766 7767 7768 7769 7770 7771 7772 7773 7774
pub fn parse_get_public_key_response(
response: &http::Response<bytes::Bytes>,
) -> std::result::Result<crate::output::GetPublicKeyOutput, crate::error::GetPublicKeyError> {
Ok({
#[allow(unused_mut)]
let mut output = crate::output::get_public_key_output::Builder::default();
let _ = response;
output = output.set_e_tag(
crate::http_serde::deser_header_get_public_key_get_public_key_output_e_tag(
response.headers(),
)
.map_err(|_| {
crate::error::GetPublicKeyError::unhandled("Failed to parse ETag from header `ETag")
})?,
);
output = output.set_public_key(
crate::http_serde::deser_payload_get_public_key_get_public_key_output_public_key(
response.body().as_ref(),
)?,
);
output.build()
})
}