#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct TlsValidationContextAcmTrust {
pub certificate_authority_arns: ::std::vec::Vec<::std::string::String>,
}
impl TlsValidationContextAcmTrust {
pub fn certificate_authority_arns(&self) -> &[::std::string::String] {
use std::ops::Deref;
self.certificate_authority_arns.deref()
}
}
impl TlsValidationContextAcmTrust {
pub fn builder() -> crate::types::builders::TlsValidationContextAcmTrustBuilder {
crate::types::builders::TlsValidationContextAcmTrustBuilder::default()
}
}
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct TlsValidationContextAcmTrustBuilder {
pub(crate) certificate_authority_arns: ::std::option::Option<::std::vec::Vec<::std::string::String>>,
}
impl TlsValidationContextAcmTrustBuilder {
pub fn certificate_authority_arns(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
let mut v = self.certificate_authority_arns.unwrap_or_default();
v.push(input.into());
self.certificate_authority_arns = ::std::option::Option::Some(v);
self
}
pub fn set_certificate_authority_arns(mut self, input: ::std::option::Option<::std::vec::Vec<::std::string::String>>) -> Self {
self.certificate_authority_arns = input;
self
}
pub fn get_certificate_authority_arns(&self) -> &::std::option::Option<::std::vec::Vec<::std::string::String>> {
&self.certificate_authority_arns
}
pub fn build(self) -> ::std::result::Result<crate::types::TlsValidationContextAcmTrust, ::aws_smithy_types::error::operation::BuildError> {
::std::result::Result::Ok(crate::types::TlsValidationContextAcmTrust {
certificate_authority_arns: self.certificate_authority_arns.ok_or_else(|| {
::aws_smithy_types::error::operation::BuildError::missing_field(
"certificate_authority_arns",
"certificate_authority_arns was not specified but it is required when building TlsValidationContextAcmTrust",
)
})?,
})
}
}