aws_sdk_transfer/operation/update_certificate/
_update_certificate_input.rs#[allow(missing_docs)] #[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct UpdateCertificateInput {
pub certificate_id: ::std::option::Option<::std::string::String>,
pub active_date: ::std::option::Option<::aws_smithy_types::DateTime>,
pub inactive_date: ::std::option::Option<::aws_smithy_types::DateTime>,
pub description: ::std::option::Option<::std::string::String>,
}
impl UpdateCertificateInput {
pub fn certificate_id(&self) -> ::std::option::Option<&str> {
self.certificate_id.as_deref()
}
pub fn active_date(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
self.active_date.as_ref()
}
pub fn inactive_date(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
self.inactive_date.as_ref()
}
pub fn description(&self) -> ::std::option::Option<&str> {
self.description.as_deref()
}
}
impl UpdateCertificateInput {
pub fn builder() -> crate::operation::update_certificate::builders::UpdateCertificateInputBuilder {
crate::operation::update_certificate::builders::UpdateCertificateInputBuilder::default()
}
}
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct UpdateCertificateInputBuilder {
pub(crate) certificate_id: ::std::option::Option<::std::string::String>,
pub(crate) active_date: ::std::option::Option<::aws_smithy_types::DateTime>,
pub(crate) inactive_date: ::std::option::Option<::aws_smithy_types::DateTime>,
pub(crate) description: ::std::option::Option<::std::string::String>,
}
impl UpdateCertificateInputBuilder {
pub fn certificate_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.certificate_id = ::std::option::Option::Some(input.into());
self
}
pub fn set_certificate_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.certificate_id = input;
self
}
pub fn get_certificate_id(&self) -> &::std::option::Option<::std::string::String> {
&self.certificate_id
}
pub fn active_date(mut self, input: ::aws_smithy_types::DateTime) -> Self {
self.active_date = ::std::option::Option::Some(input);
self
}
pub fn set_active_date(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
self.active_date = input;
self
}
pub fn get_active_date(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
&self.active_date
}
pub fn inactive_date(mut self, input: ::aws_smithy_types::DateTime) -> Self {
self.inactive_date = ::std::option::Option::Some(input);
self
}
pub fn set_inactive_date(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
self.inactive_date = input;
self
}
pub fn get_inactive_date(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
&self.inactive_date
}
pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
self.description = ::std::option::Option::Some(input.into());
self
}
pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
self.description = input;
self
}
pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
&self.description
}
pub fn build(
self,
) -> ::std::result::Result<crate::operation::update_certificate::UpdateCertificateInput, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::operation::update_certificate::UpdateCertificateInput {
certificate_id: self.certificate_id,
active_date: self.active_date,
inactive_date: self.inactive_date,
description: self.description,
})
}
}