aws-sdk-sms 1.26.0

AWS SDK for AWS Server Migration Service
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 DeleteAppInput {
    /// <p>The ID of the application.</p>
    pub app_id: ::std::option::Option<::std::string::String>,
    /// <p>Indicates whether to stop all replication jobs corresponding to the servers in the application while deleting the application.</p>
    pub force_stop_app_replication: ::std::option::Option<bool>,
    /// <p>Indicates whether to terminate the stack corresponding to the application while deleting the application.</p>
    pub force_terminate_app: ::std::option::Option<bool>,
}
impl DeleteAppInput {
    /// <p>The ID of the application.</p>
    pub fn app_id(&self) -> ::std::option::Option<&str> {
        self.app_id.as_deref()
    }
    /// <p>Indicates whether to stop all replication jobs corresponding to the servers in the application while deleting the application.</p>
    pub fn force_stop_app_replication(&self) -> ::std::option::Option<bool> {
        self.force_stop_app_replication
    }
    /// <p>Indicates whether to terminate the stack corresponding to the application while deleting the application.</p>
    pub fn force_terminate_app(&self) -> ::std::option::Option<bool> {
        self.force_terminate_app
    }
}
impl DeleteAppInput {
    /// Creates a new builder-style object to manufacture [`DeleteAppInput`](crate::operation::delete_app::DeleteAppInput).
    pub fn builder() -> crate::operation::delete_app::builders::DeleteAppInputBuilder {
        crate::operation::delete_app::builders::DeleteAppInputBuilder::default()
    }
}

/// A builder for [`DeleteAppInput`](crate::operation::delete_app::DeleteAppInput).
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
pub struct DeleteAppInputBuilder {
    pub(crate) app_id: ::std::option::Option<::std::string::String>,
    pub(crate) force_stop_app_replication: ::std::option::Option<bool>,
    pub(crate) force_terminate_app: ::std::option::Option<bool>,
}
impl DeleteAppInputBuilder {
    /// <p>The ID of the application.</p>
    pub fn app_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.app_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The ID of the application.</p>
    pub fn set_app_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.app_id = input;
        self
    }
    /// <p>The ID of the application.</p>
    pub fn get_app_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.app_id
    }
    /// <p>Indicates whether to stop all replication jobs corresponding to the servers in the application while deleting the application.</p>
    pub fn force_stop_app_replication(mut self, input: bool) -> Self {
        self.force_stop_app_replication = ::std::option::Option::Some(input);
        self
    }
    /// <p>Indicates whether to stop all replication jobs corresponding to the servers in the application while deleting the application.</p>
    pub fn set_force_stop_app_replication(mut self, input: ::std::option::Option<bool>) -> Self {
        self.force_stop_app_replication = input;
        self
    }
    /// <p>Indicates whether to stop all replication jobs corresponding to the servers in the application while deleting the application.</p>
    pub fn get_force_stop_app_replication(&self) -> &::std::option::Option<bool> {
        &self.force_stop_app_replication
    }
    /// <p>Indicates whether to terminate the stack corresponding to the application while deleting the application.</p>
    pub fn force_terminate_app(mut self, input: bool) -> Self {
        self.force_terminate_app = ::std::option::Option::Some(input);
        self
    }
    /// <p>Indicates whether to terminate the stack corresponding to the application while deleting the application.</p>
    pub fn set_force_terminate_app(mut self, input: ::std::option::Option<bool>) -> Self {
        self.force_terminate_app = input;
        self
    }
    /// <p>Indicates whether to terminate the stack corresponding to the application while deleting the application.</p>
    pub fn get_force_terminate_app(&self) -> &::std::option::Option<bool> {
        &self.force_terminate_app
    }
    /// Consumes the builder and constructs a [`DeleteAppInput`](crate::operation::delete_app::DeleteAppInput).
    pub fn build(self) -> ::std::result::Result<crate::operation::delete_app::DeleteAppInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::delete_app::DeleteAppInput {
            app_id: self.app_id,
            force_stop_app_replication: self.force_stop_app_replication,
            force_terminate_app: self.force_terminate_app,
        })
    }
}