1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
// 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,
}
}
}