aws-sdk-codegurureviewer 1.98.0

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

/// <p>Information about the statistics from the code review.</p>
#[non_exhaustive]
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
pub struct Metrics {
    /// <p><code>MeteredLinesOfCodeCount</code> is the number of lines of code in the repository where the code review happened. This does not include non-code lines such as comments and blank lines.</p>
    pub metered_lines_of_code_count: ::std::option::Option<i64>,
    /// <p><code>SuppressedLinesOfCodeCount</code> is the number of lines of code in the repository where the code review happened that CodeGuru Reviewer did not analyze. The lines suppressed in the analysis is based on the <code>excludeFiles</code> variable in the <code>aws-codeguru-reviewer.yml</code> file. This number does not include non-code lines such as comments and blank lines.</p>
    pub suppressed_lines_of_code_count: ::std::option::Option<i64>,
    /// <p>Total number of recommendations found in the code review.</p>
    pub findings_count: ::std::option::Option<i64>,
}
impl Metrics {
    /// <p><code>MeteredLinesOfCodeCount</code> is the number of lines of code in the repository where the code review happened. This does not include non-code lines such as comments and blank lines.</p>
    pub fn metered_lines_of_code_count(&self) -> ::std::option::Option<i64> {
        self.metered_lines_of_code_count
    }
    /// <p><code>SuppressedLinesOfCodeCount</code> is the number of lines of code in the repository where the code review happened that CodeGuru Reviewer did not analyze. The lines suppressed in the analysis is based on the <code>excludeFiles</code> variable in the <code>aws-codeguru-reviewer.yml</code> file. This number does not include non-code lines such as comments and blank lines.</p>
    pub fn suppressed_lines_of_code_count(&self) -> ::std::option::Option<i64> {
        self.suppressed_lines_of_code_count
    }
    /// <p>Total number of recommendations found in the code review.</p>
    pub fn findings_count(&self) -> ::std::option::Option<i64> {
        self.findings_count
    }
}
impl Metrics {
    /// Creates a new builder-style object to manufacture [`Metrics`](crate::types::Metrics).
    pub fn builder() -> crate::types::builders::MetricsBuilder {
        crate::types::builders::MetricsBuilder::default()
    }
}

/// A builder for [`Metrics`](crate::types::Metrics).
#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
#[non_exhaustive]
pub struct MetricsBuilder {
    pub(crate) metered_lines_of_code_count: ::std::option::Option<i64>,
    pub(crate) suppressed_lines_of_code_count: ::std::option::Option<i64>,
    pub(crate) findings_count: ::std::option::Option<i64>,
}
impl MetricsBuilder {
    /// <p><code>MeteredLinesOfCodeCount</code> is the number of lines of code in the repository where the code review happened. This does not include non-code lines such as comments and blank lines.</p>
    pub fn metered_lines_of_code_count(mut self, input: i64) -> Self {
        self.metered_lines_of_code_count = ::std::option::Option::Some(input);
        self
    }
    /// <p><code>MeteredLinesOfCodeCount</code> is the number of lines of code in the repository where the code review happened. This does not include non-code lines such as comments and blank lines.</p>
    pub fn set_metered_lines_of_code_count(mut self, input: ::std::option::Option<i64>) -> Self {
        self.metered_lines_of_code_count = input;
        self
    }
    /// <p><code>MeteredLinesOfCodeCount</code> is the number of lines of code in the repository where the code review happened. This does not include non-code lines such as comments and blank lines.</p>
    pub fn get_metered_lines_of_code_count(&self) -> &::std::option::Option<i64> {
        &self.metered_lines_of_code_count
    }
    /// <p><code>SuppressedLinesOfCodeCount</code> is the number of lines of code in the repository where the code review happened that CodeGuru Reviewer did not analyze. The lines suppressed in the analysis is based on the <code>excludeFiles</code> variable in the <code>aws-codeguru-reviewer.yml</code> file. This number does not include non-code lines such as comments and blank lines.</p>
    pub fn suppressed_lines_of_code_count(mut self, input: i64) -> Self {
        self.suppressed_lines_of_code_count = ::std::option::Option::Some(input);
        self
    }
    /// <p><code>SuppressedLinesOfCodeCount</code> is the number of lines of code in the repository where the code review happened that CodeGuru Reviewer did not analyze. The lines suppressed in the analysis is based on the <code>excludeFiles</code> variable in the <code>aws-codeguru-reviewer.yml</code> file. This number does not include non-code lines such as comments and blank lines.</p>
    pub fn set_suppressed_lines_of_code_count(mut self, input: ::std::option::Option<i64>) -> Self {
        self.suppressed_lines_of_code_count = input;
        self
    }
    /// <p><code>SuppressedLinesOfCodeCount</code> is the number of lines of code in the repository where the code review happened that CodeGuru Reviewer did not analyze. The lines suppressed in the analysis is based on the <code>excludeFiles</code> variable in the <code>aws-codeguru-reviewer.yml</code> file. This number does not include non-code lines such as comments and blank lines.</p>
    pub fn get_suppressed_lines_of_code_count(&self) -> &::std::option::Option<i64> {
        &self.suppressed_lines_of_code_count
    }
    /// <p>Total number of recommendations found in the code review.</p>
    pub fn findings_count(mut self, input: i64) -> Self {
        self.findings_count = ::std::option::Option::Some(input);
        self
    }
    /// <p>Total number of recommendations found in the code review.</p>
    pub fn set_findings_count(mut self, input: ::std::option::Option<i64>) -> Self {
        self.findings_count = input;
        self
    }
    /// <p>Total number of recommendations found in the code review.</p>
    pub fn get_findings_count(&self) -> &::std::option::Option<i64> {
        &self.findings_count
    }
    /// Consumes the builder and constructs a [`Metrics`](crate::types::Metrics).
    pub fn build(self) -> crate::types::Metrics {
        crate::types::Metrics {
            metered_lines_of_code_count: self.metered_lines_of_code_count,
            suppressed_lines_of_code_count: self.suppressed_lines_of_code_count,
            findings_count: self.findings_count,
        }
    }
}