aws-sdk-entityresolution 1.108.0

AWS SDK for AWS EntityResolution
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 GenerateMatchIdInput {
    /// <p>The name of the rule-based matching workflow.</p>
    pub workflow_name: ::std::option::Option<::std::string::String>,
    /// <p>The records to match.</p>
    pub records: ::std::option::Option<::std::vec::Vec<crate::types::Record>>,
    /// <p>The processing mode that determines how Match IDs are generated and results are saved. Each mode provides different levels of accuracy, response time, and completeness of results.</p>
    /// <p>If not specified, defaults to <code>CONSISTENT</code>.</p>
    /// <p><code>CONSISTENT</code>: Performs immediate lookup and matching against all existing records, with results saved synchronously. Provides highest accuracy but slower response time.</p>
    /// <p><code>EVENTUAL</code> (shown as <i>Background</i> in the console): Performs initial match ID lookup or generation immediately, with record updates processed asynchronously in the background. Offers faster initial response time, with complete matching results available later in S3.</p>
    /// <p><code>EVENTUAL_NO_LOOKUP</code> (shown as <i>Quick ID generation</i> in the console): Generates new match IDs without checking existing matches, with updates processed asynchronously. Provides fastest response time but should only be used for records known to be unique.</p>
    pub processing_type: ::std::option::Option<crate::types::ProcessingType>,
}
impl GenerateMatchIdInput {
    /// <p>The name of the rule-based matching workflow.</p>
    pub fn workflow_name(&self) -> ::std::option::Option<&str> {
        self.workflow_name.as_deref()
    }
    /// <p>The records to match.</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 `.records.is_none()`.
    pub fn records(&self) -> &[crate::types::Record] {
        self.records.as_deref().unwrap_or_default()
    }
    /// <p>The processing mode that determines how Match IDs are generated and results are saved. Each mode provides different levels of accuracy, response time, and completeness of results.</p>
    /// <p>If not specified, defaults to <code>CONSISTENT</code>.</p>
    /// <p><code>CONSISTENT</code>: Performs immediate lookup and matching against all existing records, with results saved synchronously. Provides highest accuracy but slower response time.</p>
    /// <p><code>EVENTUAL</code> (shown as <i>Background</i> in the console): Performs initial match ID lookup or generation immediately, with record updates processed asynchronously in the background. Offers faster initial response time, with complete matching results available later in S3.</p>
    /// <p><code>EVENTUAL_NO_LOOKUP</code> (shown as <i>Quick ID generation</i> in the console): Generates new match IDs without checking existing matches, with updates processed asynchronously. Provides fastest response time but should only be used for records known to be unique.</p>
    pub fn processing_type(&self) -> ::std::option::Option<&crate::types::ProcessingType> {
        self.processing_type.as_ref()
    }
}
impl GenerateMatchIdInput {
    /// Creates a new builder-style object to manufacture [`GenerateMatchIdInput`](crate::operation::generate_match_id::GenerateMatchIdInput).
    pub fn builder() -> crate::operation::generate_match_id::builders::GenerateMatchIdInputBuilder {
        crate::operation::generate_match_id::builders::GenerateMatchIdInputBuilder::default()
    }
}

/// A builder for [`GenerateMatchIdInput`](crate::operation::generate_match_id::GenerateMatchIdInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GenerateMatchIdInputBuilder {
    pub(crate) workflow_name: ::std::option::Option<::std::string::String>,
    pub(crate) records: ::std::option::Option<::std::vec::Vec<crate::types::Record>>,
    pub(crate) processing_type: ::std::option::Option<crate::types::ProcessingType>,
}
impl GenerateMatchIdInputBuilder {
    /// <p>The name of the rule-based matching workflow.</p>
    /// This field is required.
    pub fn workflow_name(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.workflow_name = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The name of the rule-based matching workflow.</p>
    pub fn set_workflow_name(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.workflow_name = input;
        self
    }
    /// <p>The name of the rule-based matching workflow.</p>
    pub fn get_workflow_name(&self) -> &::std::option::Option<::std::string::String> {
        &self.workflow_name
    }
    /// Appends an item to `records`.
    ///
    /// To override the contents of this collection use [`set_records`](Self::set_records).
    ///
    /// <p>The records to match.</p>
    pub fn records(mut self, input: crate::types::Record) -> Self {
        let mut v = self.records.unwrap_or_default();
        v.push(input);
        self.records = ::std::option::Option::Some(v);
        self
    }
    /// <p>The records to match.</p>
    pub fn set_records(mut self, input: ::std::option::Option<::std::vec::Vec<crate::types::Record>>) -> Self {
        self.records = input;
        self
    }
    /// <p>The records to match.</p>
    pub fn get_records(&self) -> &::std::option::Option<::std::vec::Vec<crate::types::Record>> {
        &self.records
    }
    /// <p>The processing mode that determines how Match IDs are generated and results are saved. Each mode provides different levels of accuracy, response time, and completeness of results.</p>
    /// <p>If not specified, defaults to <code>CONSISTENT</code>.</p>
    /// <p><code>CONSISTENT</code>: Performs immediate lookup and matching against all existing records, with results saved synchronously. Provides highest accuracy but slower response time.</p>
    /// <p><code>EVENTUAL</code> (shown as <i>Background</i> in the console): Performs initial match ID lookup or generation immediately, with record updates processed asynchronously in the background. Offers faster initial response time, with complete matching results available later in S3.</p>
    /// <p><code>EVENTUAL_NO_LOOKUP</code> (shown as <i>Quick ID generation</i> in the console): Generates new match IDs without checking existing matches, with updates processed asynchronously. Provides fastest response time but should only be used for records known to be unique.</p>
    pub fn processing_type(mut self, input: crate::types::ProcessingType) -> Self {
        self.processing_type = ::std::option::Option::Some(input);
        self
    }
    /// <p>The processing mode that determines how Match IDs are generated and results are saved. Each mode provides different levels of accuracy, response time, and completeness of results.</p>
    /// <p>If not specified, defaults to <code>CONSISTENT</code>.</p>
    /// <p><code>CONSISTENT</code>: Performs immediate lookup and matching against all existing records, with results saved synchronously. Provides highest accuracy but slower response time.</p>
    /// <p><code>EVENTUAL</code> (shown as <i>Background</i> in the console): Performs initial match ID lookup or generation immediately, with record updates processed asynchronously in the background. Offers faster initial response time, with complete matching results available later in S3.</p>
    /// <p><code>EVENTUAL_NO_LOOKUP</code> (shown as <i>Quick ID generation</i> in the console): Generates new match IDs without checking existing matches, with updates processed asynchronously. Provides fastest response time but should only be used for records known to be unique.</p>
    pub fn set_processing_type(mut self, input: ::std::option::Option<crate::types::ProcessingType>) -> Self {
        self.processing_type = input;
        self
    }
    /// <p>The processing mode that determines how Match IDs are generated and results are saved. Each mode provides different levels of accuracy, response time, and completeness of results.</p>
    /// <p>If not specified, defaults to <code>CONSISTENT</code>.</p>
    /// <p><code>CONSISTENT</code>: Performs immediate lookup and matching against all existing records, with results saved synchronously. Provides highest accuracy but slower response time.</p>
    /// <p><code>EVENTUAL</code> (shown as <i>Background</i> in the console): Performs initial match ID lookup or generation immediately, with record updates processed asynchronously in the background. Offers faster initial response time, with complete matching results available later in S3.</p>
    /// <p><code>EVENTUAL_NO_LOOKUP</code> (shown as <i>Quick ID generation</i> in the console): Generates new match IDs without checking existing matches, with updates processed asynchronously. Provides fastest response time but should only be used for records known to be unique.</p>
    pub fn get_processing_type(&self) -> &::std::option::Option<crate::types::ProcessingType> {
        &self.processing_type
    }
    /// Consumes the builder and constructs a [`GenerateMatchIdInput`](crate::operation::generate_match_id::GenerateMatchIdInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::generate_match_id::GenerateMatchIdInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::generate_match_id::GenerateMatchIdInput {
            workflow_name: self.workflow_name,
            records: self.records,
            processing_type: self.processing_type,
        })
    }
}