aws-sdk-acm 1.117.0

AWS SDK for AWS Certificate Manager
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
#[allow(missing_docs)] // documentation missing in model
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct CreateAcmeEndpointInput {
    /// <p>A unique, case-sensitive identifier to ensure idempotency of the request.</p>
    pub idempotency_token: ::std::option::Option<::std::string::String>,
    /// <p>The authorization behavior for the ACME endpoint.</p>
    pub authorization_behavior: ::std::option::Option<crate::types::AcmeAuthorizationBehavior>,
    /// <p>Specifies whether ACME clients must provide contact information during account registration.</p>
    pub contact: ::std::option::Option<crate::types::AcmeContact>,
    /// <p>The type of certificate authority to use for issuing certificates through this ACME endpoint.</p>
    pub certificate_authority: ::std::option::Option<crate::types::CertificateAuthority>,
    /// <p>One or more tags to associate with the ACME endpoint.</p>
    pub tags: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>,
    /// <p>Tags to apply to certificates issued through this ACME endpoint.</p>
    pub certificate_tags: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>,
}
impl CreateAcmeEndpointInput {
    /// <p>A unique, case-sensitive identifier to ensure idempotency of the request.</p>
    pub fn idempotency_token(&self) -> ::std::option::Option<&str> {
        self.idempotency_token.as_deref()
    }
    /// <p>The authorization behavior for the ACME endpoint.</p>
    pub fn authorization_behavior(&self) -> ::std::option::Option<&crate::types::AcmeAuthorizationBehavior> {
        self.authorization_behavior.as_ref()
    }
    /// <p>Specifies whether ACME clients must provide contact information during account registration.</p>
    pub fn contact(&self) -> ::std::option::Option<&crate::types::AcmeContact> {
        self.contact.as_ref()
    }
    /// <p>The type of certificate authority to use for issuing certificates through this ACME endpoint.</p>
    pub fn certificate_authority(&self) -> ::std::option::Option<&crate::types::CertificateAuthority> {
        self.certificate_authority.as_ref()
    }
    /// <p>One or more tags to associate with the ACME endpoint.</p>
    ///
    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.tags.is_none()`.
    pub fn tags(&self) -> &[crate::types::Tag] {
        self.tags.as_deref().unwrap_or_default()
    }
    /// <p>Tags to apply to certificates issued through this ACME endpoint.</p>
    ///
    /// If no value was sent for this field, a default will be set. If you want to determine if no value was sent, use `.certificate_tags.is_none()`.
    pub fn certificate_tags(&self) -> &[crate::types::Tag] {
        self.certificate_tags.as_deref().unwrap_or_default()
    }
}
impl CreateAcmeEndpointInput {
    /// Creates a new builder-style object to manufacture [`CreateAcmeEndpointInput`](crate::operation::create_acme_endpoint::CreateAcmeEndpointInput).
    pub fn builder() -> crate::operation::create_acme_endpoint::builders::CreateAcmeEndpointInputBuilder {
        crate::operation::create_acme_endpoint::builders::CreateAcmeEndpointInputBuilder::default()
    }
}

/// A builder for [`CreateAcmeEndpointInput`](crate::operation::create_acme_endpoint::CreateAcmeEndpointInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct CreateAcmeEndpointInputBuilder {
    pub(crate) idempotency_token: ::std::option::Option<::std::string::String>,
    pub(crate) authorization_behavior: ::std::option::Option<crate::types::AcmeAuthorizationBehavior>,
    pub(crate) contact: ::std::option::Option<crate::types::AcmeContact>,
    pub(crate) certificate_authority: ::std::option::Option<crate::types::CertificateAuthority>,
    pub(crate) tags: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>,
    pub(crate) certificate_tags: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>,
}
impl CreateAcmeEndpointInputBuilder {
    /// <p>A unique, case-sensitive identifier to ensure idempotency of the request.</p>
    pub fn idempotency_token(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.idempotency_token = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>A unique, case-sensitive identifier to ensure idempotency of the request.</p>
    pub fn set_idempotency_token(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.idempotency_token = input;
        self
    }
    /// <p>A unique, case-sensitive identifier to ensure idempotency of the request.</p>
    pub fn get_idempotency_token(&self) -> &::std::option::Option<::std::string::String> {
        &self.idempotency_token
    }
    /// <p>The authorization behavior for the ACME endpoint.</p>
    /// This field is required.
    pub fn authorization_behavior(mut self, input: crate::types::AcmeAuthorizationBehavior) -> Self {
        self.authorization_behavior = ::std::option::Option::Some(input);
        self
    }
    /// <p>The authorization behavior for the ACME endpoint.</p>
    pub fn set_authorization_behavior(mut self, input: ::std::option::Option<crate::types::AcmeAuthorizationBehavior>) -> Self {
        self.authorization_behavior = input;
        self
    }
    /// <p>The authorization behavior for the ACME endpoint.</p>
    pub fn get_authorization_behavior(&self) -> &::std::option::Option<crate::types::AcmeAuthorizationBehavior> {
        &self.authorization_behavior
    }
    /// <p>Specifies whether ACME clients must provide contact information during account registration.</p>
    pub fn contact(mut self, input: crate::types::AcmeContact) -> Self {
        self.contact = ::std::option::Option::Some(input);
        self
    }
    /// <p>Specifies whether ACME clients must provide contact information during account registration.</p>
    pub fn set_contact(mut self, input: ::std::option::Option<crate::types::AcmeContact>) -> Self {
        self.contact = input;
        self
    }
    /// <p>Specifies whether ACME clients must provide contact information during account registration.</p>
    pub fn get_contact(&self) -> &::std::option::Option<crate::types::AcmeContact> {
        &self.contact
    }
    /// <p>The type of certificate authority to use for issuing certificates through this ACME endpoint.</p>
    /// This field is required.
    pub fn certificate_authority(mut self, input: crate::types::CertificateAuthority) -> Self {
        self.certificate_authority = ::std::option::Option::Some(input);
        self
    }
    /// <p>The type of certificate authority to use for issuing certificates through this ACME endpoint.</p>
    pub fn set_certificate_authority(mut self, input: ::std::option::Option<crate::types::CertificateAuthority>) -> Self {
        self.certificate_authority = input;
        self
    }
    /// <p>The type of certificate authority to use for issuing certificates through this ACME endpoint.</p>
    pub fn get_certificate_authority(&self) -> &::std::option::Option<crate::types::CertificateAuthority> {
        &self.certificate_authority
    }
    /// Appends an item to `tags`.
    ///
    /// To override the contents of this collection use [`set_tags`](Self::set_tags).
    ///
    /// <p>One or more tags to associate with the ACME endpoint.</p>
    pub fn tags(mut self, input: crate::types::Tag) -> Self {
        let mut v = self.tags.unwrap_or_default();
        v.push(input);
        self.tags = ::std::option::Option::Some(v);
        self
    }
    /// <p>One or more tags to associate with the ACME endpoint.</p>
    pub fn set_tags(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>) -> Self {
        self.tags = input;
        self
    }
    /// <p>One or more tags to associate with the ACME endpoint.</p>
    pub fn get_tags(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Tag>> {
        &self.tags
    }
    /// Appends an item to `certificate_tags`.
    ///
    /// To override the contents of this collection use [`set_certificate_tags`](Self::set_certificate_tags).
    ///
    /// <p>Tags to apply to certificates issued through this ACME endpoint.</p>
    pub fn certificate_tags(mut self, input: crate::types::Tag) -> Self {
        let mut v = self.certificate_tags.unwrap_or_default();
        v.push(input);
        self.certificate_tags = ::std::option::Option::Some(v);
        self
    }
    /// <p>Tags to apply to certificates issued through this ACME endpoint.</p>
    pub fn set_certificate_tags(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Tag>>) -> Self {
        self.certificate_tags = input;
        self
    }
    /// <p>Tags to apply to certificates issued through this ACME endpoint.</p>
    pub fn get_certificate_tags(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Tag>> {
        &self.certificate_tags
    }
    /// Consumes the builder and constructs a [`CreateAcmeEndpointInput`](crate::operation::create_acme_endpoint::CreateAcmeEndpointInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::create_acme_endpoint::CreateAcmeEndpointInput, ::aws_smithy_types::error::operation::BuildError>
    {
        ::std::result::Result::Ok(crate::operation::create_acme_endpoint::CreateAcmeEndpointInput {
            idempotency_token: self.idempotency_token,
            authorization_behavior: self.authorization_behavior,
            contact: self.contact,
            certificate_authority: self.certificate_authority,
            tags: self.tags,
            certificate_tags: self.certificate_tags,
        })
    }
}