aws-sdk-appconfig 1.98.0

AWS SDK for Amazon AppConfig
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 GetDeploymentInput {
    /// <p>The ID of the application that includes the deployment you want to get.</p>
    pub application_id: ::std::option::Option<::std::string::String>,
    /// <p>The ID of the environment that includes the deployment you want to get.</p>
    pub environment_id: ::std::option::Option<::std::string::String>,
    /// <p>The sequence number of the deployment.</p>
    pub deployment_number: ::std::option::Option<i32>,
}
impl GetDeploymentInput {
    /// <p>The ID of the application that includes the deployment you want to get.</p>
    pub fn application_id(&self) -> ::std::option::Option<&str> {
        self.application_id.as_deref()
    }
    /// <p>The ID of the environment that includes the deployment you want to get.</p>
    pub fn environment_id(&self) -> ::std::option::Option<&str> {
        self.environment_id.as_deref()
    }
    /// <p>The sequence number of the deployment.</p>
    pub fn deployment_number(&self) -> ::std::option::Option<i32> {
        self.deployment_number
    }
}
impl GetDeploymentInput {
    /// Creates a new builder-style object to manufacture [`GetDeploymentInput`](crate::operation::get_deployment::GetDeploymentInput).
    pub fn builder() -> crate::operation::get_deployment::builders::GetDeploymentInputBuilder {
        crate::operation::get_deployment::builders::GetDeploymentInputBuilder::default()
    }
}

/// A builder for [`GetDeploymentInput`](crate::operation::get_deployment::GetDeploymentInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GetDeploymentInputBuilder {
    pub(crate) application_id: ::std::option::Option<::std::string::String>,
    pub(crate) environment_id: ::std::option::Option<::std::string::String>,
    pub(crate) deployment_number: ::std::option::Option<i32>,
}
impl GetDeploymentInputBuilder {
    /// <p>The ID of the application that includes the deployment you want to get.</p>
    /// This field is required.
    pub fn application_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.application_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ID of the application that includes the deployment you want to get.</p>
    pub fn set_application_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.application_id = input;
        self
    }
    /// <p>The ID of the application that includes the deployment you want to get.</p>
    pub fn get_application_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.application_id
    }
    /// <p>The ID of the environment that includes the deployment you want to get.</p>
    /// This field is required.
    pub fn environment_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.environment_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ID of the environment that includes the deployment you want to get.</p>
    pub fn set_environment_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.environment_id = input;
        self
    }
    /// <p>The ID of the environment that includes the deployment you want to get.</p>
    pub fn get_environment_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.environment_id
    }
    /// <p>The sequence number of the deployment.</p>
    /// This field is required.
    pub fn deployment_number(mut self, input: i32) -> Self {
        self.deployment_number = ::std::option::Option::Some(input);
        self
    }
    /// <p>The sequence number of the deployment.</p>
    pub fn set_deployment_number(mut self, input: ::std::option::Option<i32>) -> Self {
        self.deployment_number = input;
        self
    }
    /// <p>The sequence number of the deployment.</p>
    pub fn get_deployment_number(&self) -> &::std::option::Option<i32> {
        &self.deployment_number
    }
    /// Consumes the builder and constructs a [`GetDeploymentInput`](crate::operation::get_deployment::GetDeploymentInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::get_deployment::GetDeploymentInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::get_deployment::GetDeploymentInput {
            application_id: self.application_id,
            environment_id: self.environment_id,
            deployment_number: self.deployment_number,
        })
    }
}