#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct GetSolFunctionPackageMetadata {
pub vnfd: ::std::option::Option<crate::types::FunctionArtifactMeta>,
pub created_at: ::aws_smithy_types::DateTime,
pub last_modified: ::aws_smithy_types::DateTime,
}
impl GetSolFunctionPackageMetadata {
pub fn vnfd(&self) -> ::std::option::Option<&crate::types::FunctionArtifactMeta> {
self.vnfd.as_ref()
}
pub fn created_at(&self) -> &::aws_smithy_types::DateTime {
&self.created_at
}
pub fn last_modified(&self) -> &::aws_smithy_types::DateTime {
&self.last_modified
}
}
impl GetSolFunctionPackageMetadata {
pub fn builder() -> crate::types::builders::GetSolFunctionPackageMetadataBuilder {
crate::types::builders::GetSolFunctionPackageMetadataBuilder::default()
}
}
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GetSolFunctionPackageMetadataBuilder {
pub(crate) vnfd: ::std::option::Option<crate::types::FunctionArtifactMeta>,
pub(crate) created_at: ::std::option::Option<::aws_smithy_types::DateTime>,
pub(crate) last_modified: ::std::option::Option<::aws_smithy_types::DateTime>,
}
impl GetSolFunctionPackageMetadataBuilder {
pub fn vnfd(mut self, input: crate::types::FunctionArtifactMeta) -> Self {
self.vnfd = ::std::option::Option::Some(input);
self
}
pub fn set_vnfd(mut self, input: ::std::option::Option<crate::types::FunctionArtifactMeta>) -> Self {
self.vnfd = input;
self
}
pub fn get_vnfd(&self) -> &::std::option::Option<crate::types::FunctionArtifactMeta> {
&self.vnfd
}
pub fn created_at(mut self, input: ::aws_smithy_types::DateTime) -> Self {
self.created_at = ::std::option::Option::Some(input);
self
}
pub fn set_created_at(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
self.created_at = input;
self
}
pub fn get_created_at(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
&self.created_at
}
pub fn last_modified(mut self, input: ::aws_smithy_types::DateTime) -> Self {
self.last_modified = ::std::option::Option::Some(input);
self
}
pub fn set_last_modified(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
self.last_modified = input;
self
}
pub fn get_last_modified(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
&self.last_modified
}
pub fn build(self) -> ::std::result::Result<crate::types::GetSolFunctionPackageMetadata, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::types::GetSolFunctionPackageMetadata {
vnfd: self.vnfd,
created_at: self.created_at.ok_or_else(|| {
::aws_smithy_types::error::operation::BuildError::missing_field(
"created_at",
"created_at was not specified but it is required when building GetSolFunctionPackageMetadata",
)
})?,
last_modified: self.last_modified.ok_or_else(|| {
::aws_smithy_types::error::operation::BuildError::missing_field(
"last_modified",
"last_modified was not specified but it is required when building GetSolFunctionPackageMetadata",
)
})?,
})
}
}