aws-sdk-databasemigration 1.115.0

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

/// <p>Provides information about the progress of the schema conversion operation.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct Progress {
    /// <p>The percent complete for the current step of the schema conversion operation.</p>
    pub progress_percent: ::std::option::Option<f64>,
    /// <p>The number of objects in this schema conversion operation.</p>
    pub total_objects: i64,
    /// <p>The step of the schema conversion operation. This parameter can store one of the following values:</p>
    /// <ul>
    /// <li>
    /// <p><code>IN_PROGRESS</code> – The operation is running.</p></li>
    /// <li>
    /// <p><code>LOADING_METADATA</code> – Loads metadata from the source database.</p></li>
    /// <li>
    /// <p><code>COUNTING_OBJECTS</code> – Determines the number of objects involved in the operation.</p></li>
    /// <li>
    /// <p><code>ANALYZING</code> – Analyzes the source database objects.</p></li>
    /// <li>
    /// <p><code>CONVERTING</code> – Converts the source database objects to a format compatible with the target database.</p></li>
    /// <li>
    /// <p><code>APPLYING</code> – Applies the converted code to the target database.</p></li>
    /// <li>
    /// <p><code>FINISHED</code> – The operation completed successfully.</p></li>
    /// </ul>
    pub progress_step: ::std::option::Option<::std::string::String>,
    /// <p>The name of the database object that the schema conversion operation currently uses.</p>
    pub processed_object: ::std::option::Option<crate::types::ProcessedObject>,
}
impl Progress {
    /// <p>The percent complete for the current step of the schema conversion operation.</p>
    pub fn progress_percent(&self) -> ::std::option::Option<f64> {
        self.progress_percent
    }
    /// <p>The number of objects in this schema conversion operation.</p>
    pub fn total_objects(&self) -> i64 {
        self.total_objects
    }
    /// <p>The step of the schema conversion operation. This parameter can store one of the following values:</p>
    /// <ul>
    /// <li>
    /// <p><code>IN_PROGRESS</code> – The operation is running.</p></li>
    /// <li>
    /// <p><code>LOADING_METADATA</code> – Loads metadata from the source database.</p></li>
    /// <li>
    /// <p><code>COUNTING_OBJECTS</code> – Determines the number of objects involved in the operation.</p></li>
    /// <li>
    /// <p><code>ANALYZING</code> – Analyzes the source database objects.</p></li>
    /// <li>
    /// <p><code>CONVERTING</code> – Converts the source database objects to a format compatible with the target database.</p></li>
    /// <li>
    /// <p><code>APPLYING</code> – Applies the converted code to the target database.</p></li>
    /// <li>
    /// <p><code>FINISHED</code> – The operation completed successfully.</p></li>
    /// </ul>
    pub fn progress_step(&self) -> ::std::option::Option<&str> {
        self.progress_step.as_deref()
    }
    /// <p>The name of the database object that the schema conversion operation currently uses.</p>
    pub fn processed_object(&self) -> ::std::option::Option<&crate::types::ProcessedObject> {
        self.processed_object.as_ref()
    }
}
impl Progress {
    /// Creates a new builder-style object to manufacture [`Progress`](crate::types::Progress).
    pub fn builder() -> crate::types::builders::ProgressBuilder {
        crate::types::builders::ProgressBuilder::default()
    }
}

/// A builder for [`Progress`](crate::types::Progress).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct ProgressBuilder {
    pub(crate) progress_percent: ::std::option::Option<f64>,
    pub(crate) total_objects: ::std::option::Option<i64>,
    pub(crate) progress_step: ::std::option::Option<::std::string::String>,
    pub(crate) processed_object: ::std::option::Option<crate::types::ProcessedObject>,
}
impl ProgressBuilder {
    /// <p>The percent complete for the current step of the schema conversion operation.</p>
    pub fn progress_percent(mut self, input: f64) -> Self {
        self.progress_percent = ::std::option::Option::Some(input);
        self
    }
    /// <p>The percent complete for the current step of the schema conversion operation.</p>
    pub fn set_progress_percent(mut self, input: ::std::option::Option<f64>) -> Self {
        self.progress_percent = input;
        self
    }
    /// <p>The percent complete for the current step of the schema conversion operation.</p>
    pub fn get_progress_percent(&self) -> &::std::option::Option<f64> {
        &self.progress_percent
    }
    /// <p>The number of objects in this schema conversion operation.</p>
    pub fn total_objects(mut self, input: i64) -> Self {
        self.total_objects = ::std::option::Option::Some(input);
        self
    }
    /// <p>The number of objects in this schema conversion operation.</p>
    pub fn set_total_objects(mut self, input: ::std::option::Option<i64>) -> Self {
        self.total_objects = input;
        self
    }
    /// <p>The number of objects in this schema conversion operation.</p>
    pub fn get_total_objects(&self) -> &::std::option::Option<i64> {
        &self.total_objects
    }
    /// <p>The step of the schema conversion operation. This parameter can store one of the following values:</p>
    /// <ul>
    /// <li>
    /// <p><code>IN_PROGRESS</code> – The operation is running.</p></li>
    /// <li>
    /// <p><code>LOADING_METADATA</code> – Loads metadata from the source database.</p></li>
    /// <li>
    /// <p><code>COUNTING_OBJECTS</code> – Determines the number of objects involved in the operation.</p></li>
    /// <li>
    /// <p><code>ANALYZING</code> – Analyzes the source database objects.</p></li>
    /// <li>
    /// <p><code>CONVERTING</code> – Converts the source database objects to a format compatible with the target database.</p></li>
    /// <li>
    /// <p><code>APPLYING</code> – Applies the converted code to the target database.</p></li>
    /// <li>
    /// <p><code>FINISHED</code> – The operation completed successfully.</p></li>
    /// </ul>
    pub fn progress_step(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.progress_step = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The step of the schema conversion operation. This parameter can store one of the following values:</p>
    /// <ul>
    /// <li>
    /// <p><code>IN_PROGRESS</code> – The operation is running.</p></li>
    /// <li>
    /// <p><code>LOADING_METADATA</code> – Loads metadata from the source database.</p></li>
    /// <li>
    /// <p><code>COUNTING_OBJECTS</code> – Determines the number of objects involved in the operation.</p></li>
    /// <li>
    /// <p><code>ANALYZING</code> – Analyzes the source database objects.</p></li>
    /// <li>
    /// <p><code>CONVERTING</code> – Converts the source database objects to a format compatible with the target database.</p></li>
    /// <li>
    /// <p><code>APPLYING</code> – Applies the converted code to the target database.</p></li>
    /// <li>
    /// <p><code>FINISHED</code> – The operation completed successfully.</p></li>
    /// </ul>
    pub fn set_progress_step(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.progress_step = input;
        self
    }
    /// <p>The step of the schema conversion operation. This parameter can store one of the following values:</p>
    /// <ul>
    /// <li>
    /// <p><code>IN_PROGRESS</code> – The operation is running.</p></li>
    /// <li>
    /// <p><code>LOADING_METADATA</code> – Loads metadata from the source database.</p></li>
    /// <li>
    /// <p><code>COUNTING_OBJECTS</code> – Determines the number of objects involved in the operation.</p></li>
    /// <li>
    /// <p><code>ANALYZING</code> – Analyzes the source database objects.</p></li>
    /// <li>
    /// <p><code>CONVERTING</code> – Converts the source database objects to a format compatible with the target database.</p></li>
    /// <li>
    /// <p><code>APPLYING</code> – Applies the converted code to the target database.</p></li>
    /// <li>
    /// <p><code>FINISHED</code> – The operation completed successfully.</p></li>
    /// </ul>
    pub fn get_progress_step(&self) -> &::std::option::Option<::std::string::String> {
        &self.progress_step
    }
    /// <p>The name of the database object that the schema conversion operation currently uses.</p>
    pub fn processed_object(mut self, input: crate::types::ProcessedObject) -> Self {
        self.processed_object = ::std::option::Option::Some(input);
        self
    }
    /// <p>The name of the database object that the schema conversion operation currently uses.</p>
    pub fn set_processed_object(mut self, input: ::std::option::Option<crate::types::ProcessedObject>) -> Self {
        self.processed_object = input;
        self
    }
    /// <p>The name of the database object that the schema conversion operation currently uses.</p>
    pub fn get_processed_object(&self) -> &::std::option::Option<crate::types::ProcessedObject> {
        &self.processed_object
    }
    /// Consumes the builder and constructs a [`Progress`](crate::types::Progress).
    pub fn build(self) -> crate::types::Progress {
        crate::types::Progress {
            progress_percent: self.progress_percent,
            total_objects: self.total_objects.unwrap_or_default(),
            progress_step: self.progress_step,
            processed_object: self.processed_object,
        }
    }
}