#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct ExportAssetToSignedUrlResponseDetails {
pub asset_id: ::std::string::String,
pub data_set_id: ::std::string::String,
pub revision_id: ::std::string::String,
pub signed_url: ::std::option::Option<::std::string::String>,
pub signed_url_expires_at: ::std::option::Option<::aws_smithy_types::DateTime>,
}
impl ExportAssetToSignedUrlResponseDetails {
pub fn asset_id(&self) -> &str {
use std::ops::Deref;
self.asset_id.deref()
}
pub fn data_set_id(&self) -> &str {
use std::ops::Deref;
self.data_set_id.deref()
}
pub fn revision_id(&self) -> &str {
use std::ops::Deref;
self.revision_id.deref()
}
pub fn signed_url(&self) -> ::std::option::Option<&str> {
self.signed_url.as_deref()
}
pub fn signed_url_expires_at(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
self.signed_url_expires_at.as_ref()
}
}
impl ExportAssetToSignedUrlResponseDetails {
pub fn builder() -> crate::types::builders::ExportAssetToSignedUrlResponseDetailsBuilder {
crate::types::builders::ExportAssetToSignedUrlResponseDetailsBuilder::default()
}
}
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct ExportAssetToSignedUrlResponseDetailsBuilder {
pub(crate) asset_id: ::std::option::Option<::std::string::String>,
pub(crate) data_set_id: ::std::option::Option<::std::string::String>,
pub(crate) revision_id: ::std::option::Option<::std::string::String>,
pub(crate) signed_url: ::std::option::Option<::std::string::String>,
pub(crate) signed_url_expires_at: ::std::option::Option<::aws_smithy_types::DateTime>,
}
impl ExportAssetToSignedUrlResponseDetailsBuilder {
pub fn asset_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.asset_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_asset_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.asset_id = input;
self
}
pub fn get_asset_id(&self) -> &::std::option::Option<::std::string::String> {
&self.asset_id
}
pub fn data_set_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.data_set_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_data_set_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.data_set_id = input;
self
}
pub fn get_data_set_id(&self) -> &::std::option::Option<::std::string::String> {
&self.data_set_id
}
pub fn revision_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.revision_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_revision_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.revision_id = input;
self
}
pub fn get_revision_id(&self) -> &::std::option::Option<::std::string::String> {
&self.revision_id
}
pub fn signed_url(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.signed_url = ::std::option::Option::Some(input.into());
self
}
pub fn set_signed_url(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.signed_url = input;
self
}
pub fn get_signed_url(&self) -> &::std::option::Option<::std::string::String> {
&self.signed_url
}
pub fn signed_url_expires_at(mut self, input: ::aws_smithy_types::DateTime) -> Self {
self.signed_url_expires_at = ::std::option::Option::Some(input);
self
}
pub fn set_signed_url_expires_at(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
self.signed_url_expires_at = input;
self
}
pub fn get_signed_url_expires_at(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
&self.signed_url_expires_at
}
pub fn build(
self,
) -> ::std::result::Result<crate::types::ExportAssetToSignedUrlResponseDetails, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::types::ExportAssetToSignedUrlResponseDetails {
asset_id: self.asset_id.ok_or_else(|| {
::aws_smithy_types::error::operation::BuildError::missing_field(
"asset_id",
"asset_id was not specified but it is required when building ExportAssetToSignedUrlResponseDetails",
)
})?,
data_set_id: self.data_set_id.ok_or_else(|| {
::aws_smithy_types::error::operation::BuildError::missing_field(
"data_set_id",
"data_set_id was not specified but it is required when building ExportAssetToSignedUrlResponseDetails",
)
})?,
revision_id: self.revision_id.ok_or_else(|| {
::aws_smithy_types::error::operation::BuildError::missing_field(
"revision_id",
"revision_id was not specified but it is required when building ExportAssetToSignedUrlResponseDetails",
)
})?,
signed_url: self.signed_url,
signed_url_expires_at: self.signed_url_expires_at,
})
}
}