aws-sdk-lexmodelsv2 1.111.0

AWS SDK for Amazon Lex Model Building V2
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 StartTestExecutionOutput {
    /// <p>The unique identifier of the test set execution.</p>
    pub test_execution_id: ::std::option::Option<::std::string::String>,
    /// <p>The creation date and time for the test set execution.</p>
    pub creation_date_time: ::std::option::Option<::aws_smithy_types::DateTime>,
    /// <p>The test set Id for the test set execution.</p>
    pub test_set_id: ::std::option::Option<::std::string::String>,
    /// <p>The target bot for the test set execution.</p>
    pub target: ::std::option::Option<crate::types::TestExecutionTarget>,
    /// <p>Indicates whether we use streaming or non-streaming APIs for the test set execution. For streaming, StartConversation Amazon Lex Runtime API is used. Whereas for non-streaming, RecognizeUtterance and RecognizeText Amazon Lex Runtime API are used.</p>
    pub api_mode: ::std::option::Option<crate::types::TestExecutionApiMode>,
    /// <p>Indicates whether audio or text is used.</p>
    pub test_execution_modality: ::std::option::Option<crate::types::TestExecutionModality>,
    _request_id: Option<String>,
}
impl StartTestExecutionOutput {
    /// <p>The unique identifier of the test set execution.</p>
    pub fn test_execution_id(&self) -> ::std::option::Option<&str> {
        self.test_execution_id.as_deref()
    }
    /// <p>The creation date and time for the test set execution.</p>
    pub fn creation_date_time(&self) -> ::std::option::Option<&::aws_smithy_types::DateTime> {
        self.creation_date_time.as_ref()
    }
    /// <p>The test set Id for the test set execution.</p>
    pub fn test_set_id(&self) -> ::std::option::Option<&str> {
        self.test_set_id.as_deref()
    }
    /// <p>The target bot for the test set execution.</p>
    pub fn target(&self) -> ::std::option::Option<&crate::types::TestExecutionTarget> {
        self.target.as_ref()
    }
    /// <p>Indicates whether we use streaming or non-streaming APIs for the test set execution. For streaming, StartConversation Amazon Lex Runtime API is used. Whereas for non-streaming, RecognizeUtterance and RecognizeText Amazon Lex Runtime API are used.</p>
    pub fn api_mode(&self) -> ::std::option::Option<&crate::types::TestExecutionApiMode> {
        self.api_mode.as_ref()
    }
    /// <p>Indicates whether audio or text is used.</p>
    pub fn test_execution_modality(&self) -> ::std::option::Option<&crate::types::TestExecutionModality> {
        self.test_execution_modality.as_ref()
    }
}
impl ::aws_types::request_id::RequestId for StartTestExecutionOutput {
    fn request_id(&self) -> Option<&str> {
        self._request_id.as_deref()
    }
}
impl StartTestExecutionOutput {
    /// Creates a new builder-style object to manufacture [`StartTestExecutionOutput`](crate::operation::start_test_execution::StartTestExecutionOutput).
    pub fn builder() -> crate::operation::start_test_execution::builders::StartTestExecutionOutputBuilder {
        crate::operation::start_test_execution::builders::StartTestExecutionOutputBuilder::default()
    }
}

/// A builder for [`StartTestExecutionOutput`](crate::operation::start_test_execution::StartTestExecutionOutput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct StartTestExecutionOutputBuilder {
    pub(crate) test_execution_id: ::std::option::Option<::std::string::String>,
    pub(crate) creation_date_time: ::std::option::Option<::aws_smithy_types::DateTime>,
    pub(crate) test_set_id: ::std::option::Option<::std::string::String>,
    pub(crate) target: ::std::option::Option<crate::types::TestExecutionTarget>,
    pub(crate) api_mode: ::std::option::Option<crate::types::TestExecutionApiMode>,
    pub(crate) test_execution_modality: ::std::option::Option<crate::types::TestExecutionModality>,
    _request_id: Option<String>,
}
impl StartTestExecutionOutputBuilder {
    /// <p>The unique identifier of the test set execution.</p>
    pub fn test_execution_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.test_execution_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The unique identifier of the test set execution.</p>
    pub fn set_test_execution_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.test_execution_id = input;
        self
    }
    /// <p>The unique identifier of the test set execution.</p>
    pub fn get_test_execution_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.test_execution_id
    }
    /// <p>The creation date and time for the test set execution.</p>
    pub fn creation_date_time(mut self, input: ::aws_smithy_types::DateTime) -> Self {
        self.creation_date_time = ::std::option::Option::Some(input);
        self
    }
    /// <p>The creation date and time for the test set execution.</p>
    pub fn set_creation_date_time(mut self, input: ::std::option::Option<::aws_smithy_types::DateTime>) -> Self {
        self.creation_date_time = input;
        self
    }
    /// <p>The creation date and time for the test set execution.</p>
    pub fn get_creation_date_time(&self) -> &::std::option::Option<::aws_smithy_types::DateTime> {
        &self.creation_date_time
    }
    /// <p>The test set Id for the test set execution.</p>
    pub fn test_set_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.test_set_id = ::std::option::Option::Some(input.into());
        self
    }
    /// <p>The test set Id for the test set execution.</p>
    pub fn set_test_set_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.test_set_id = input;
        self
    }
    /// <p>The test set Id for the test set execution.</p>
    pub fn get_test_set_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.test_set_id
    }
    /// <p>The target bot for the test set execution.</p>
    pub fn target(mut self, input: crate::types::TestExecutionTarget) -> Self {
        self.target = ::std::option::Option::Some(input);
        self
    }
    /// <p>The target bot for the test set execution.</p>
    pub fn set_target(mut self, input: ::std::option::Option<crate::types::TestExecutionTarget>) -> Self {
        self.target = input;
        self
    }
    /// <p>The target bot for the test set execution.</p>
    pub fn get_target(&self) -> &::std::option::Option<crate::types::TestExecutionTarget> {
        &self.target
    }
    /// <p>Indicates whether we use streaming or non-streaming APIs for the test set execution. For streaming, StartConversation Amazon Lex Runtime API is used. Whereas for non-streaming, RecognizeUtterance and RecognizeText Amazon Lex Runtime API are used.</p>
    pub fn api_mode(mut self, input: crate::types::TestExecutionApiMode) -> Self {
        self.api_mode = ::std::option::Option::Some(input);
        self
    }
    /// <p>Indicates whether we use streaming or non-streaming APIs for the test set execution. For streaming, StartConversation Amazon Lex Runtime API is used. Whereas for non-streaming, RecognizeUtterance and RecognizeText Amazon Lex Runtime API are used.</p>
    pub fn set_api_mode(mut self, input: ::std::option::Option<crate::types::TestExecutionApiMode>) -> Self {
        self.api_mode = input;
        self
    }
    /// <p>Indicates whether we use streaming or non-streaming APIs for the test set execution. For streaming, StartConversation Amazon Lex Runtime API is used. Whereas for non-streaming, RecognizeUtterance and RecognizeText Amazon Lex Runtime API are used.</p>
    pub fn get_api_mode(&self) -> &::std::option::Option<crate::types::TestExecutionApiMode> {
        &self.api_mode
    }
    /// <p>Indicates whether audio or text is used.</p>
    pub fn test_execution_modality(mut self, input: crate::types::TestExecutionModality) -> Self {
        self.test_execution_modality = ::std::option::Option::Some(input);
        self
    }
    /// <p>Indicates whether audio or text is used.</p>
    pub fn set_test_execution_modality(mut self, input: ::std::option::Option<crate::types::TestExecutionModality>) -> Self {
        self.test_execution_modality = input;
        self
    }
    /// <p>Indicates whether audio or text is used.</p>
    pub fn get_test_execution_modality(&self) -> &::std::option::Option<crate::types::TestExecutionModality> {
        &self.test_execution_modality
    }
    pub(crate) fn _request_id(mut self, request_id: impl Into<String>) -> Self {
        self._request_id = Some(request_id.into());
        self
    }

    pub(crate) fn _set_request_id(&mut self, request_id: Option<String>) -> &mut Self {
        self._request_id = request_id;
        self
    }
    /// Consumes the builder and constructs a [`StartTestExecutionOutput`](crate::operation::start_test_execution::StartTestExecutionOutput).
    pub fn build(self) -> crate::operation::start_test_execution::StartTestExecutionOutput {
        crate::operation::start_test_execution::StartTestExecutionOutput {
            test_execution_id: self.test_execution_id,
            creation_date_time: self.creation_date_time,
            test_set_id: self.test_set_id,
            target: self.target,
            api_mode: self.api_mode,
            test_execution_modality: self.test_execution_modality,
            _request_id: self._request_id,
        }
    }
}