aws-sdk-amplify 1.111.0

AWS SDK for AWS Amplify
Documentation
// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.

/// <p>Describes the backend associated with an Amplify <code>Branch</code>.</p>
/// <p>This property is available to Amplify Gen 2 apps only. When you deploy an application with Amplify Gen 2, you provision the app's backend infrastructure using Typescript code.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct Backend {
    /// <p>The Amazon Resource Name (ARN) for the CloudFormation stack.</p>
    pub stack_arn: ::std::option::Option<::std::string::String>,
}
impl Backend {
    /// <p>The Amazon Resource Name (ARN) for the CloudFormation stack.</p>
    pub fn stack_arn(&self) -> ::std::option::Option<&str> {
        self.stack_arn.as_deref()
    }
}
impl Backend {
    /// Creates a new builder-style object to manufacture [`Backend`](crate::types::Backend).
    pub fn builder() -> crate::types::builders::BackendBuilder {
        crate::types::builders::BackendBuilder::default()
    }
}

/// A builder for [`Backend`](crate::types::Backend).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct BackendBuilder {
    pub(crate) stack_arn: ::std::option::Option<::std::string::String>,
}
impl BackendBuilder {
    /// <p>The Amazon Resource Name (ARN) for the CloudFormation stack.</p>
    pub fn stack_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.stack_arn = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The Amazon Resource Name (ARN) for the CloudFormation stack.</p>
    pub fn set_stack_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.stack_arn = input;
        self
    }
    /// <p>The Amazon Resource Name (ARN) for the CloudFormation stack.</p>
    pub fn get_stack_arn(&self) -> &::std::option::Option<::std::string::String> {
        &self.stack_arn
    }
    /// Consumes the builder and constructs a [`Backend`](crate::types::Backend).
    pub fn build(self) -> crate::types::Backend {
        crate::types::Backend { stack_arn: self.stack_arn }
    }
}