/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include #include #include #include namespace Aws { namespace CodeGuruSecurity { namespace Model { /** */ class CreateScanRequest : public CodeGuruSecurityRequest { public: AWS_CODEGURUSECURITY_API CreateScanRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "CreateScan"; } AWS_CODEGURUSECURITY_API Aws::String SerializePayload() const override; /** *

The type of analysis you want CodeGuru Security to perform in the scan, * either Security or All. The Security type * only generates findings related to security. The All type generates * both security findings and quality findings. Defaults to Security * type if missing.

*/ inline const AnalysisType& GetAnalysisType() const{ return m_analysisType; } /** *

The type of analysis you want CodeGuru Security to perform in the scan, * either Security or All. The Security type * only generates findings related to security. The All type generates * both security findings and quality findings. Defaults to Security * type if missing.

*/ inline bool AnalysisTypeHasBeenSet() const { return m_analysisTypeHasBeenSet; } /** *

The type of analysis you want CodeGuru Security to perform in the scan, * either Security or All. The Security type * only generates findings related to security. The All type generates * both security findings and quality findings. Defaults to Security * type if missing.

*/ inline void SetAnalysisType(const AnalysisType& value) { m_analysisTypeHasBeenSet = true; m_analysisType = value; } /** *

The type of analysis you want CodeGuru Security to perform in the scan, * either Security or All. The Security type * only generates findings related to security. The All type generates * both security findings and quality findings. Defaults to Security * type if missing.

*/ inline void SetAnalysisType(AnalysisType&& value) { m_analysisTypeHasBeenSet = true; m_analysisType = std::move(value); } /** *

The type of analysis you want CodeGuru Security to perform in the scan, * either Security or All. The Security type * only generates findings related to security. The All type generates * both security findings and quality findings. Defaults to Security * type if missing.

*/ inline CreateScanRequest& WithAnalysisType(const AnalysisType& value) { SetAnalysisType(value); return *this;} /** *

The type of analysis you want CodeGuru Security to perform in the scan, * either Security or All. The Security type * only generates findings related to security. The All type generates * both security findings and quality findings. Defaults to Security * type if missing.

*/ inline CreateScanRequest& WithAnalysisType(AnalysisType&& value) { SetAnalysisType(std::move(value)); return *this;} /** *

The idempotency token for the request. Amazon CodeGuru Security uses this * value to prevent the accidental creation of duplicate scans if there are * failures and retries.

*/ inline const Aws::String& GetClientToken() const{ return m_clientToken; } /** *

The idempotency token for the request. Amazon CodeGuru Security uses this * value to prevent the accidental creation of duplicate scans if there are * failures and retries.

*/ inline bool ClientTokenHasBeenSet() const { return m_clientTokenHasBeenSet; } /** *

The idempotency token for the request. Amazon CodeGuru Security uses this * value to prevent the accidental creation of duplicate scans if there are * failures and retries.

*/ inline void SetClientToken(const Aws::String& value) { m_clientTokenHasBeenSet = true; m_clientToken = value; } /** *

The idempotency token for the request. Amazon CodeGuru Security uses this * value to prevent the accidental creation of duplicate scans if there are * failures and retries.

*/ inline void SetClientToken(Aws::String&& value) { m_clientTokenHasBeenSet = true; m_clientToken = std::move(value); } /** *

The idempotency token for the request. Amazon CodeGuru Security uses this * value to prevent the accidental creation of duplicate scans if there are * failures and retries.

*/ inline void SetClientToken(const char* value) { m_clientTokenHasBeenSet = true; m_clientToken.assign(value); } /** *

The idempotency token for the request. Amazon CodeGuru Security uses this * value to prevent the accidental creation of duplicate scans if there are * failures and retries.

*/ inline CreateScanRequest& WithClientToken(const Aws::String& value) { SetClientToken(value); return *this;} /** *

The idempotency token for the request. Amazon CodeGuru Security uses this * value to prevent the accidental creation of duplicate scans if there are * failures and retries.

*/ inline CreateScanRequest& WithClientToken(Aws::String&& value) { SetClientToken(std::move(value)); return *this;} /** *

The idempotency token for the request. Amazon CodeGuru Security uses this * value to prevent the accidental creation of duplicate scans if there are * failures and retries.

*/ inline CreateScanRequest& WithClientToken(const char* value) { SetClientToken(value); return *this;} /** *

The identifier for an input resource used to create a scan.

*/ inline const ResourceId& GetResourceId() const{ return m_resourceId; } /** *

The identifier for an input resource used to create a scan.

*/ inline bool ResourceIdHasBeenSet() const { return m_resourceIdHasBeenSet; } /** *

The identifier for an input resource used to create a scan.

*/ inline void SetResourceId(const ResourceId& value) { m_resourceIdHasBeenSet = true; m_resourceId = value; } /** *

The identifier for an input resource used to create a scan.

*/ inline void SetResourceId(ResourceId&& value) { m_resourceIdHasBeenSet = true; m_resourceId = std::move(value); } /** *

The identifier for an input resource used to create a scan.

*/ inline CreateScanRequest& WithResourceId(const ResourceId& value) { SetResourceId(value); return *this;} /** *

The identifier for an input resource used to create a scan.

*/ inline CreateScanRequest& WithResourceId(ResourceId&& value) { SetResourceId(std::move(value)); return *this;} /** *

The unique name that CodeGuru Security uses to track revisions across * multiple scans of the same resource. Only allowed for a STANDARD * scan type. If not specified, it will be auto generated.

*/ inline const Aws::String& GetScanName() const{ return m_scanName; } /** *

The unique name that CodeGuru Security uses to track revisions across * multiple scans of the same resource. Only allowed for a STANDARD * scan type. If not specified, it will be auto generated.

*/ inline bool ScanNameHasBeenSet() const { return m_scanNameHasBeenSet; } /** *

The unique name that CodeGuru Security uses to track revisions across * multiple scans of the same resource. Only allowed for a STANDARD * scan type. If not specified, it will be auto generated.

*/ inline void SetScanName(const Aws::String& value) { m_scanNameHasBeenSet = true; m_scanName = value; } /** *

The unique name that CodeGuru Security uses to track revisions across * multiple scans of the same resource. Only allowed for a STANDARD * scan type. If not specified, it will be auto generated.

*/ inline void SetScanName(Aws::String&& value) { m_scanNameHasBeenSet = true; m_scanName = std::move(value); } /** *

The unique name that CodeGuru Security uses to track revisions across * multiple scans of the same resource. Only allowed for a STANDARD * scan type. If not specified, it will be auto generated.

*/ inline void SetScanName(const char* value) { m_scanNameHasBeenSet = true; m_scanName.assign(value); } /** *

The unique name that CodeGuru Security uses to track revisions across * multiple scans of the same resource. Only allowed for a STANDARD * scan type. If not specified, it will be auto generated.

*/ inline CreateScanRequest& WithScanName(const Aws::String& value) { SetScanName(value); return *this;} /** *

The unique name that CodeGuru Security uses to track revisions across * multiple scans of the same resource. Only allowed for a STANDARD * scan type. If not specified, it will be auto generated.

*/ inline CreateScanRequest& WithScanName(Aws::String&& value) { SetScanName(std::move(value)); return *this;} /** *

The unique name that CodeGuru Security uses to track revisions across * multiple scans of the same resource. Only allowed for a STANDARD * scan type. If not specified, it will be auto generated.

*/ inline CreateScanRequest& WithScanName(const char* value) { SetScanName(value); return *this;} /** *

The type of scan, either Standard or Express. * Defaults to Standard type if missing.

Express * scans run on limited resources and use a limited set of detectors to analyze * your code in near-real time. Standard scans have standard resource * limits and use the full set of detectors to analyze your code.

*/ inline const ScanType& GetScanType() const{ return m_scanType; } /** *

The type of scan, either Standard or Express. * Defaults to Standard type if missing.

Express * scans run on limited resources and use a limited set of detectors to analyze * your code in near-real time. Standard scans have standard resource * limits and use the full set of detectors to analyze your code.

*/ inline bool ScanTypeHasBeenSet() const { return m_scanTypeHasBeenSet; } /** *

The type of scan, either Standard or Express. * Defaults to Standard type if missing.

Express * scans run on limited resources and use a limited set of detectors to analyze * your code in near-real time. Standard scans have standard resource * limits and use the full set of detectors to analyze your code.

*/ inline void SetScanType(const ScanType& value) { m_scanTypeHasBeenSet = true; m_scanType = value; } /** *

The type of scan, either Standard or Express. * Defaults to Standard type if missing.

Express * scans run on limited resources and use a limited set of detectors to analyze * your code in near-real time. Standard scans have standard resource * limits and use the full set of detectors to analyze your code.

*/ inline void SetScanType(ScanType&& value) { m_scanTypeHasBeenSet = true; m_scanType = std::move(value); } /** *

The type of scan, either Standard or Express. * Defaults to Standard type if missing.

Express * scans run on limited resources and use a limited set of detectors to analyze * your code in near-real time. Standard scans have standard resource * limits and use the full set of detectors to analyze your code.

*/ inline CreateScanRequest& WithScanType(const ScanType& value) { SetScanType(value); return *this;} /** *

The type of scan, either Standard or Express. * Defaults to Standard type if missing.

Express * scans run on limited resources and use a limited set of detectors to analyze * your code in near-real time. Standard scans have standard resource * limits and use the full set of detectors to analyze your code.

*/ inline CreateScanRequest& WithScanType(ScanType&& value) { SetScanType(std::move(value)); return *this;} /** *

An array of key-value pairs used to tag a scan. A tag is a custom attribute * label with two parts:

  • A tag key. For example, * CostCenter, Environment, or Secret. Tag * keys are case sensitive.

  • An optional tag value field. For * example, 111122223333, Production, or a team name. * Omitting the tag value is the same as using an empty string. Tag values are case * sensitive.

*/ inline const Aws::Map& GetTags() const{ return m_tags; } /** *

An array of key-value pairs used to tag a scan. A tag is a custom attribute * label with two parts:

  • A tag key. For example, * CostCenter, Environment, or Secret. Tag * keys are case sensitive.

  • An optional tag value field. For * example, 111122223333, Production, or a team name. * Omitting the tag value is the same as using an empty string. Tag values are case * sensitive.

*/ inline bool TagsHasBeenSet() const { return m_tagsHasBeenSet; } /** *

An array of key-value pairs used to tag a scan. A tag is a custom attribute * label with two parts:

  • A tag key. For example, * CostCenter, Environment, or Secret. Tag * keys are case sensitive.

  • An optional tag value field. For * example, 111122223333, Production, or a team name. * Omitting the tag value is the same as using an empty string. Tag values are case * sensitive.

*/ inline void SetTags(const Aws::Map& value) { m_tagsHasBeenSet = true; m_tags = value; } /** *

An array of key-value pairs used to tag a scan. A tag is a custom attribute * label with two parts:

  • A tag key. For example, * CostCenter, Environment, or Secret. Tag * keys are case sensitive.

  • An optional tag value field. For * example, 111122223333, Production, or a team name. * Omitting the tag value is the same as using an empty string. Tag values are case * sensitive.

*/ inline void SetTags(Aws::Map&& value) { m_tagsHasBeenSet = true; m_tags = std::move(value); } /** *

An array of key-value pairs used to tag a scan. A tag is a custom attribute * label with two parts:

  • A tag key. For example, * CostCenter, Environment, or Secret. Tag * keys are case sensitive.

  • An optional tag value field. For * example, 111122223333, Production, or a team name. * Omitting the tag value is the same as using an empty string. Tag values are case * sensitive.

*/ inline CreateScanRequest& WithTags(const Aws::Map& value) { SetTags(value); return *this;} /** *

An array of key-value pairs used to tag a scan. A tag is a custom attribute * label with two parts:

  • A tag key. For example, * CostCenter, Environment, or Secret. Tag * keys are case sensitive.

  • An optional tag value field. For * example, 111122223333, Production, or a team name. * Omitting the tag value is the same as using an empty string. Tag values are case * sensitive.

*/ inline CreateScanRequest& WithTags(Aws::Map&& value) { SetTags(std::move(value)); return *this;} /** *

An array of key-value pairs used to tag a scan. A tag is a custom attribute * label with two parts:

  • A tag key. For example, * CostCenter, Environment, or Secret. Tag * keys are case sensitive.

  • An optional tag value field. For * example, 111122223333, Production, or a team name. * Omitting the tag value is the same as using an empty string. Tag values are case * sensitive.

*/ inline CreateScanRequest& AddTags(const Aws::String& key, const Aws::String& value) { m_tagsHasBeenSet = true; m_tags.emplace(key, value); return *this; } /** *

An array of key-value pairs used to tag a scan. A tag is a custom attribute * label with two parts:

  • A tag key. For example, * CostCenter, Environment, or Secret. Tag * keys are case sensitive.

  • An optional tag value field. For * example, 111122223333, Production, or a team name. * Omitting the tag value is the same as using an empty string. Tag values are case * sensitive.

*/ inline CreateScanRequest& AddTags(Aws::String&& key, const Aws::String& value) { m_tagsHasBeenSet = true; m_tags.emplace(std::move(key), value); return *this; } /** *

An array of key-value pairs used to tag a scan. A tag is a custom attribute * label with two parts:

  • A tag key. For example, * CostCenter, Environment, or Secret. Tag * keys are case sensitive.

  • An optional tag value field. For * example, 111122223333, Production, or a team name. * Omitting the tag value is the same as using an empty string. Tag values are case * sensitive.

*/ inline CreateScanRequest& AddTags(const Aws::String& key, Aws::String&& value) { m_tagsHasBeenSet = true; m_tags.emplace(key, std::move(value)); return *this; } /** *

An array of key-value pairs used to tag a scan. A tag is a custom attribute * label with two parts:

  • A tag key. For example, * CostCenter, Environment, or Secret. Tag * keys are case sensitive.

  • An optional tag value field. For * example, 111122223333, Production, or a team name. * Omitting the tag value is the same as using an empty string. Tag values are case * sensitive.

*/ inline CreateScanRequest& AddTags(Aws::String&& key, Aws::String&& value) { m_tagsHasBeenSet = true; m_tags.emplace(std::move(key), std::move(value)); return *this; } /** *

An array of key-value pairs used to tag a scan. A tag is a custom attribute * label with two parts:

  • A tag key. For example, * CostCenter, Environment, or Secret. Tag * keys are case sensitive.

  • An optional tag value field. For * example, 111122223333, Production, or a team name. * Omitting the tag value is the same as using an empty string. Tag values are case * sensitive.

*/ inline CreateScanRequest& AddTags(const char* key, Aws::String&& value) { m_tagsHasBeenSet = true; m_tags.emplace(key, std::move(value)); return *this; } /** *

An array of key-value pairs used to tag a scan. A tag is a custom attribute * label with two parts:

  • A tag key. For example, * CostCenter, Environment, or Secret. Tag * keys are case sensitive.

  • An optional tag value field. For * example, 111122223333, Production, or a team name. * Omitting the tag value is the same as using an empty string. Tag values are case * sensitive.

*/ inline CreateScanRequest& AddTags(Aws::String&& key, const char* value) { m_tagsHasBeenSet = true; m_tags.emplace(std::move(key), value); return *this; } /** *

An array of key-value pairs used to tag a scan. A tag is a custom attribute * label with two parts:

  • A tag key. For example, * CostCenter, Environment, or Secret. Tag * keys are case sensitive.

  • An optional tag value field. For * example, 111122223333, Production, or a team name. * Omitting the tag value is the same as using an empty string. Tag values are case * sensitive.

*/ inline CreateScanRequest& AddTags(const char* key, const char* value) { m_tagsHasBeenSet = true; m_tags.emplace(key, value); return *this; } private: AnalysisType m_analysisType; bool m_analysisTypeHasBeenSet = false; Aws::String m_clientToken; bool m_clientTokenHasBeenSet = false; ResourceId m_resourceId; bool m_resourceIdHasBeenSet = false; Aws::String m_scanName; bool m_scanNameHasBeenSet = false; ScanType m_scanType; bool m_scanTypeHasBeenSet = false; Aws::Map m_tags; bool m_tagsHasBeenSet = false; }; } // namespace Model } // namespace CodeGuruSecurity } // namespace Aws