aws-sdk-continuum 1.0.0

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

/// Specifies the finding to retrieve.
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct GetCodeFindingInput {
    /// The environment that owns the finding.
    pub environment_id: ::std::option::Option<::std::string::String>,
    /// The unique identifier of the finding to retrieve.
    pub finding_id: ::std::option::Option<::std::string::String>,
}
impl GetCodeFindingInput {
    /// The environment that owns the finding.
    pub fn environment_id(&self) -> ::std::option::Option<&str> {
        self.environment_id.as_deref()
    }
    /// The unique identifier of the finding to retrieve.
    pub fn finding_id(&self) -> ::std::option::Option<&str> {
        self.finding_id.as_deref()
    }
}
impl GetCodeFindingInput {
    /// Creates a new builder-style object to manufacture [`GetCodeFindingInput`](crate::operation::get_code_finding::GetCodeFindingInput).
    pub fn builder() -> crate::operation::get_code_finding::builders::GetCodeFindingInputBuilder {
        crate::operation::get_code_finding::builders::GetCodeFindingInputBuilder::default()
    }
}

/// A builder for [`GetCodeFindingInput`](crate::operation::get_code_finding::GetCodeFindingInput).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct GetCodeFindingInputBuilder {
    pub(crate) environment_id: ::std::option::Option<::std::string::String>,
    pub(crate) finding_id: ::std::option::Option<::std::string::String>,
}
impl GetCodeFindingInputBuilder {
    /// The environment that owns the finding.
    /// 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
    }
    /// The environment that owns the finding.
    pub fn set_environment_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.environment_id = input;
        self
    }
    /// The environment that owns the finding.
    pub fn get_environment_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.environment_id
    }
    /// The unique identifier of the finding to retrieve.
    /// This field is required.
    pub fn finding_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
        self.finding_id = ::std::option::Option::Some(input.into());
        self
    }
    /// The unique identifier of the finding to retrieve.
    pub fn set_finding_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
        self.finding_id = input;
        self
    }
    /// The unique identifier of the finding to retrieve.
    pub fn get_finding_id(&self) -> &::std::option::Option<::std::string::String> {
        &self.finding_id
    }
    /// Consumes the builder and constructs a [`GetCodeFindingInput`](crate::operation::get_code_finding::GetCodeFindingInput).
    pub fn build(
        self,
    ) -> ::std::result::Result<crate::operation::get_code_finding::GetCodeFindingInput, ::aws_smithy_types::error::operation::BuildError> {
        ::std::result::Result::Ok(crate::operation::get_code_finding::GetCodeFindingInput {
            environment_id: self.environment_id,
            finding_id: self.finding_id,
        })
    }
}