/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace CodeGuruReviewer { namespace Model { /** *

Information about recommendations.

See Also:

AWS * API Reference

*/ class RecommendationSummary { public: AWS_CODEGURUREVIEWER_API RecommendationSummary(); AWS_CODEGURUREVIEWER_API RecommendationSummary(Aws::Utils::Json::JsonView jsonValue); AWS_CODEGURUREVIEWER_API RecommendationSummary& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_CODEGURUREVIEWER_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

Name of the file on which a recommendation is provided.

*/ inline const Aws::String& GetFilePath() const{ return m_filePath; } /** *

Name of the file on which a recommendation is provided.

*/ inline bool FilePathHasBeenSet() const { return m_filePathHasBeenSet; } /** *

Name of the file on which a recommendation is provided.

*/ inline void SetFilePath(const Aws::String& value) { m_filePathHasBeenSet = true; m_filePath = value; } /** *

Name of the file on which a recommendation is provided.

*/ inline void SetFilePath(Aws::String&& value) { m_filePathHasBeenSet = true; m_filePath = std::move(value); } /** *

Name of the file on which a recommendation is provided.

*/ inline void SetFilePath(const char* value) { m_filePathHasBeenSet = true; m_filePath.assign(value); } /** *

Name of the file on which a recommendation is provided.

*/ inline RecommendationSummary& WithFilePath(const Aws::String& value) { SetFilePath(value); return *this;} /** *

Name of the file on which a recommendation is provided.

*/ inline RecommendationSummary& WithFilePath(Aws::String&& value) { SetFilePath(std::move(value)); return *this;} /** *

Name of the file on which a recommendation is provided.

*/ inline RecommendationSummary& WithFilePath(const char* value) { SetFilePath(value); return *this;} /** *

The recommendation ID that can be used to track the provided recommendations. * Later on it can be used to collect the feedback.

*/ inline const Aws::String& GetRecommendationId() const{ return m_recommendationId; } /** *

The recommendation ID that can be used to track the provided recommendations. * Later on it can be used to collect the feedback.

*/ inline bool RecommendationIdHasBeenSet() const { return m_recommendationIdHasBeenSet; } /** *

The recommendation ID that can be used to track the provided recommendations. * Later on it can be used to collect the feedback.

*/ inline void SetRecommendationId(const Aws::String& value) { m_recommendationIdHasBeenSet = true; m_recommendationId = value; } /** *

The recommendation ID that can be used to track the provided recommendations. * Later on it can be used to collect the feedback.

*/ inline void SetRecommendationId(Aws::String&& value) { m_recommendationIdHasBeenSet = true; m_recommendationId = std::move(value); } /** *

The recommendation ID that can be used to track the provided recommendations. * Later on it can be used to collect the feedback.

*/ inline void SetRecommendationId(const char* value) { m_recommendationIdHasBeenSet = true; m_recommendationId.assign(value); } /** *

The recommendation ID that can be used to track the provided recommendations. * Later on it can be used to collect the feedback.

*/ inline RecommendationSummary& WithRecommendationId(const Aws::String& value) { SetRecommendationId(value); return *this;} /** *

The recommendation ID that can be used to track the provided recommendations. * Later on it can be used to collect the feedback.

*/ inline RecommendationSummary& WithRecommendationId(Aws::String&& value) { SetRecommendationId(std::move(value)); return *this;} /** *

The recommendation ID that can be used to track the provided recommendations. * Later on it can be used to collect the feedback.

*/ inline RecommendationSummary& WithRecommendationId(const char* value) { SetRecommendationId(value); return *this;} /** *

Start line from where the recommendation is applicable in the source commit * or source branch.

*/ inline int GetStartLine() const{ return m_startLine; } /** *

Start line from where the recommendation is applicable in the source commit * or source branch.

*/ inline bool StartLineHasBeenSet() const { return m_startLineHasBeenSet; } /** *

Start line from where the recommendation is applicable in the source commit * or source branch.

*/ inline void SetStartLine(int value) { m_startLineHasBeenSet = true; m_startLine = value; } /** *

Start line from where the recommendation is applicable in the source commit * or source branch.

*/ inline RecommendationSummary& WithStartLine(int value) { SetStartLine(value); return *this;} /** *

Last line where the recommendation is applicable in the source commit or * source branch. For a single line comment the start line and end line values are * the same.

*/ inline int GetEndLine() const{ return m_endLine; } /** *

Last line where the recommendation is applicable in the source commit or * source branch. For a single line comment the start line and end line values are * the same.

*/ inline bool EndLineHasBeenSet() const { return m_endLineHasBeenSet; } /** *

Last line where the recommendation is applicable in the source commit or * source branch. For a single line comment the start line and end line values are * the same.

*/ inline void SetEndLine(int value) { m_endLineHasBeenSet = true; m_endLine = value; } /** *

Last line where the recommendation is applicable in the source commit or * source branch. For a single line comment the start line and end line values are * the same.

*/ inline RecommendationSummary& WithEndLine(int value) { SetEndLine(value); return *this;} /** *

A description of the recommendation generated by CodeGuru Reviewer for the * lines of code between the start line and the end line.

*/ inline const Aws::String& GetDescription() const{ return m_description; } /** *

A description of the recommendation generated by CodeGuru Reviewer for the * lines of code between the start line and the end line.

*/ inline bool DescriptionHasBeenSet() const { return m_descriptionHasBeenSet; } /** *

A description of the recommendation generated by CodeGuru Reviewer for the * lines of code between the start line and the end line.

*/ inline void SetDescription(const Aws::String& value) { m_descriptionHasBeenSet = true; m_description = value; } /** *

A description of the recommendation generated by CodeGuru Reviewer for the * lines of code between the start line and the end line.

*/ inline void SetDescription(Aws::String&& value) { m_descriptionHasBeenSet = true; m_description = std::move(value); } /** *

A description of the recommendation generated by CodeGuru Reviewer for the * lines of code between the start line and the end line.

*/ inline void SetDescription(const char* value) { m_descriptionHasBeenSet = true; m_description.assign(value); } /** *

A description of the recommendation generated by CodeGuru Reviewer for the * lines of code between the start line and the end line.

*/ inline RecommendationSummary& WithDescription(const Aws::String& value) { SetDescription(value); return *this;} /** *

A description of the recommendation generated by CodeGuru Reviewer for the * lines of code between the start line and the end line.

*/ inline RecommendationSummary& WithDescription(Aws::String&& value) { SetDescription(std::move(value)); return *this;} /** *

A description of the recommendation generated by CodeGuru Reviewer for the * lines of code between the start line and the end line.

*/ inline RecommendationSummary& WithDescription(const char* value) { SetDescription(value); return *this;} /** *

The type of a recommendation.

*/ inline const RecommendationCategory& GetRecommendationCategory() const{ return m_recommendationCategory; } /** *

The type of a recommendation.

*/ inline bool RecommendationCategoryHasBeenSet() const { return m_recommendationCategoryHasBeenSet; } /** *

The type of a recommendation.

*/ inline void SetRecommendationCategory(const RecommendationCategory& value) { m_recommendationCategoryHasBeenSet = true; m_recommendationCategory = value; } /** *

The type of a recommendation.

*/ inline void SetRecommendationCategory(RecommendationCategory&& value) { m_recommendationCategoryHasBeenSet = true; m_recommendationCategory = std::move(value); } /** *

The type of a recommendation.

*/ inline RecommendationSummary& WithRecommendationCategory(const RecommendationCategory& value) { SetRecommendationCategory(value); return *this;} /** *

The type of a recommendation.

*/ inline RecommendationSummary& WithRecommendationCategory(RecommendationCategory&& value) { SetRecommendationCategory(std::move(value)); return *this;} /** *

Metadata about a rule. Rule metadata includes an ID, a name, a list of tags, * and a short and long description. CodeGuru Reviewer uses rules to analyze code. * A rule's recommendation is included in analysis results if code is detected that * violates the rule.

*/ inline const RuleMetadata& GetRuleMetadata() const{ return m_ruleMetadata; } /** *

Metadata about a rule. Rule metadata includes an ID, a name, a list of tags, * and a short and long description. CodeGuru Reviewer uses rules to analyze code. * A rule's recommendation is included in analysis results if code is detected that * violates the rule.

*/ inline bool RuleMetadataHasBeenSet() const { return m_ruleMetadataHasBeenSet; } /** *

Metadata about a rule. Rule metadata includes an ID, a name, a list of tags, * and a short and long description. CodeGuru Reviewer uses rules to analyze code. * A rule's recommendation is included in analysis results if code is detected that * violates the rule.

*/ inline void SetRuleMetadata(const RuleMetadata& value) { m_ruleMetadataHasBeenSet = true; m_ruleMetadata = value; } /** *

Metadata about a rule. Rule metadata includes an ID, a name, a list of tags, * and a short and long description. CodeGuru Reviewer uses rules to analyze code. * A rule's recommendation is included in analysis results if code is detected that * violates the rule.

*/ inline void SetRuleMetadata(RuleMetadata&& value) { m_ruleMetadataHasBeenSet = true; m_ruleMetadata = std::move(value); } /** *

Metadata about a rule. Rule metadata includes an ID, a name, a list of tags, * and a short and long description. CodeGuru Reviewer uses rules to analyze code. * A rule's recommendation is included in analysis results if code is detected that * violates the rule.

*/ inline RecommendationSummary& WithRuleMetadata(const RuleMetadata& value) { SetRuleMetadata(value); return *this;} /** *

Metadata about a rule. Rule metadata includes an ID, a name, a list of tags, * and a short and long description. CodeGuru Reviewer uses rules to analyze code. * A rule's recommendation is included in analysis results if code is detected that * violates the rule.

*/ inline RecommendationSummary& WithRuleMetadata(RuleMetadata&& value) { SetRuleMetadata(std::move(value)); return *this;} /** *

The severity of the issue in the code that generated this recommendation.

*/ inline const Severity& GetSeverity() const{ return m_severity; } /** *

The severity of the issue in the code that generated this recommendation.

*/ inline bool SeverityHasBeenSet() const { return m_severityHasBeenSet; } /** *

The severity of the issue in the code that generated this recommendation.

*/ inline void SetSeverity(const Severity& value) { m_severityHasBeenSet = true; m_severity = value; } /** *

The severity of the issue in the code that generated this recommendation.

*/ inline void SetSeverity(Severity&& value) { m_severityHasBeenSet = true; m_severity = std::move(value); } /** *

The severity of the issue in the code that generated this recommendation.

*/ inline RecommendationSummary& WithSeverity(const Severity& value) { SetSeverity(value); return *this;} /** *

The severity of the issue in the code that generated this recommendation.

*/ inline RecommendationSummary& WithSeverity(Severity&& value) { SetSeverity(std::move(value)); return *this;} private: Aws::String m_filePath; bool m_filePathHasBeenSet = false; Aws::String m_recommendationId; bool m_recommendationIdHasBeenSet = false; int m_startLine; bool m_startLineHasBeenSet = false; int m_endLine; bool m_endLineHasBeenSet = false; Aws::String m_description; bool m_descriptionHasBeenSet = false; RecommendationCategory m_recommendationCategory; bool m_recommendationCategoryHasBeenSet = false; RuleMetadata m_ruleMetadata; bool m_ruleMetadataHasBeenSet = false; Severity m_severity; bool m_severityHasBeenSet = false; }; } // namespace Model } // namespace CodeGuruReviewer } // namespace Aws