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

Information about an environment variable for a build project or a * build.

See Also:

AWS * API Reference

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

The name or key of the environment variable.

*/ inline const Aws::String& GetName() const{ return m_name; } /** *

The name or key of the environment variable.

*/ inline bool NameHasBeenSet() const { return m_nameHasBeenSet; } /** *

The name or key of the environment variable.

*/ inline void SetName(const Aws::String& value) { m_nameHasBeenSet = true; m_name = value; } /** *

The name or key of the environment variable.

*/ inline void SetName(Aws::String&& value) { m_nameHasBeenSet = true; m_name = std::move(value); } /** *

The name or key of the environment variable.

*/ inline void SetName(const char* value) { m_nameHasBeenSet = true; m_name.assign(value); } /** *

The name or key of the environment variable.

*/ inline EnvironmentVariable& WithName(const Aws::String& value) { SetName(value); return *this;} /** *

The name or key of the environment variable.

*/ inline EnvironmentVariable& WithName(Aws::String&& value) { SetName(std::move(value)); return *this;} /** *

The name or key of the environment variable.

*/ inline EnvironmentVariable& WithName(const char* value) { SetName(value); return *this;} /** *

The value of the environment variable.

We strongly * discourage the use of PLAINTEXT environment variables to store * sensitive values, especially Amazon Web Services secret key IDs and secret * access keys. PLAINTEXT environment variables can be displayed in * plain text using the CodeBuild console and the CLI. For sensitive values, we * recommend you use an environment variable of type PARAMETER_STORE * or SECRETS_MANAGER.

*/ inline const Aws::String& GetValue() const{ return m_value; } /** *

The value of the environment variable.

We strongly * discourage the use of PLAINTEXT environment variables to store * sensitive values, especially Amazon Web Services secret key IDs and secret * access keys. PLAINTEXT environment variables can be displayed in * plain text using the CodeBuild console and the CLI. For sensitive values, we * recommend you use an environment variable of type PARAMETER_STORE * or SECRETS_MANAGER.

*/ inline bool ValueHasBeenSet() const { return m_valueHasBeenSet; } /** *

The value of the environment variable.

We strongly * discourage the use of PLAINTEXT environment variables to store * sensitive values, especially Amazon Web Services secret key IDs and secret * access keys. PLAINTEXT environment variables can be displayed in * plain text using the CodeBuild console and the CLI. For sensitive values, we * recommend you use an environment variable of type PARAMETER_STORE * or SECRETS_MANAGER.

*/ inline void SetValue(const Aws::String& value) { m_valueHasBeenSet = true; m_value = value; } /** *

The value of the environment variable.

We strongly * discourage the use of PLAINTEXT environment variables to store * sensitive values, especially Amazon Web Services secret key IDs and secret * access keys. PLAINTEXT environment variables can be displayed in * plain text using the CodeBuild console and the CLI. For sensitive values, we * recommend you use an environment variable of type PARAMETER_STORE * or SECRETS_MANAGER.

*/ inline void SetValue(Aws::String&& value) { m_valueHasBeenSet = true; m_value = std::move(value); } /** *

The value of the environment variable.

We strongly * discourage the use of PLAINTEXT environment variables to store * sensitive values, especially Amazon Web Services secret key IDs and secret * access keys. PLAINTEXT environment variables can be displayed in * plain text using the CodeBuild console and the CLI. For sensitive values, we * recommend you use an environment variable of type PARAMETER_STORE * or SECRETS_MANAGER.

*/ inline void SetValue(const char* value) { m_valueHasBeenSet = true; m_value.assign(value); } /** *

The value of the environment variable.

We strongly * discourage the use of PLAINTEXT environment variables to store * sensitive values, especially Amazon Web Services secret key IDs and secret * access keys. PLAINTEXT environment variables can be displayed in * plain text using the CodeBuild console and the CLI. For sensitive values, we * recommend you use an environment variable of type PARAMETER_STORE * or SECRETS_MANAGER.

*/ inline EnvironmentVariable& WithValue(const Aws::String& value) { SetValue(value); return *this;} /** *

The value of the environment variable.

We strongly * discourage the use of PLAINTEXT environment variables to store * sensitive values, especially Amazon Web Services secret key IDs and secret * access keys. PLAINTEXT environment variables can be displayed in * plain text using the CodeBuild console and the CLI. For sensitive values, we * recommend you use an environment variable of type PARAMETER_STORE * or SECRETS_MANAGER.

*/ inline EnvironmentVariable& WithValue(Aws::String&& value) { SetValue(std::move(value)); return *this;} /** *

The value of the environment variable.

We strongly * discourage the use of PLAINTEXT environment variables to store * sensitive values, especially Amazon Web Services secret key IDs and secret * access keys. PLAINTEXT environment variables can be displayed in * plain text using the CodeBuild console and the CLI. For sensitive values, we * recommend you use an environment variable of type PARAMETER_STORE * or SECRETS_MANAGER.

*/ inline EnvironmentVariable& WithValue(const char* value) { SetValue(value); return *this;} /** *

The type of environment variable. Valid values include:

  • * PARAMETER_STORE: An environment variable stored in Systems Manager * Parameter Store. To learn how to specify a parameter store environment variable, * see env/parameter-store * in the CodeBuild User Guide.

  • PLAINTEXT: * An environment variable in plain text format. This is the default value.

    *
  • SECRETS_MANAGER: An environment variable stored in * Secrets Manager. To learn how to specify a secrets manager environment variable, * see env/secrets-manager * in the CodeBuild User Guide.

*/ inline const EnvironmentVariableType& GetType() const{ return m_type; } /** *

The type of environment variable. Valid values include:

  • * PARAMETER_STORE: An environment variable stored in Systems Manager * Parameter Store. To learn how to specify a parameter store environment variable, * see env/parameter-store * in the CodeBuild User Guide.

  • PLAINTEXT: * An environment variable in plain text format. This is the default value.

    *
  • SECRETS_MANAGER: An environment variable stored in * Secrets Manager. To learn how to specify a secrets manager environment variable, * see env/secrets-manager * in the CodeBuild User Guide.

*/ inline bool TypeHasBeenSet() const { return m_typeHasBeenSet; } /** *

The type of environment variable. Valid values include:

  • * PARAMETER_STORE: An environment variable stored in Systems Manager * Parameter Store. To learn how to specify a parameter store environment variable, * see env/parameter-store * in the CodeBuild User Guide.

  • PLAINTEXT: * An environment variable in plain text format. This is the default value.

    *
  • SECRETS_MANAGER: An environment variable stored in * Secrets Manager. To learn how to specify a secrets manager environment variable, * see env/secrets-manager * in the CodeBuild User Guide.

*/ inline void SetType(const EnvironmentVariableType& value) { m_typeHasBeenSet = true; m_type = value; } /** *

The type of environment variable. Valid values include:

  • * PARAMETER_STORE: An environment variable stored in Systems Manager * Parameter Store. To learn how to specify a parameter store environment variable, * see env/parameter-store * in the CodeBuild User Guide.

  • PLAINTEXT: * An environment variable in plain text format. This is the default value.

    *
  • SECRETS_MANAGER: An environment variable stored in * Secrets Manager. To learn how to specify a secrets manager environment variable, * see env/secrets-manager * in the CodeBuild User Guide.

*/ inline void SetType(EnvironmentVariableType&& value) { m_typeHasBeenSet = true; m_type = std::move(value); } /** *

The type of environment variable. Valid values include:

  • * PARAMETER_STORE: An environment variable stored in Systems Manager * Parameter Store. To learn how to specify a parameter store environment variable, * see env/parameter-store * in the CodeBuild User Guide.

  • PLAINTEXT: * An environment variable in plain text format. This is the default value.

    *
  • SECRETS_MANAGER: An environment variable stored in * Secrets Manager. To learn how to specify a secrets manager environment variable, * see env/secrets-manager * in the CodeBuild User Guide.

*/ inline EnvironmentVariable& WithType(const EnvironmentVariableType& value) { SetType(value); return *this;} /** *

The type of environment variable. Valid values include:

  • * PARAMETER_STORE: An environment variable stored in Systems Manager * Parameter Store. To learn how to specify a parameter store environment variable, * see env/parameter-store * in the CodeBuild User Guide.

  • PLAINTEXT: * An environment variable in plain text format. This is the default value.

    *
  • SECRETS_MANAGER: An environment variable stored in * Secrets Manager. To learn how to specify a secrets manager environment variable, * see env/secrets-manager * in the CodeBuild User Guide.

*/ inline EnvironmentVariable& WithType(EnvironmentVariableType&& value) { SetType(std::move(value)); return *this;} private: Aws::String m_name; bool m_nameHasBeenSet = false; Aws::String m_value; bool m_valueHasBeenSet = false; EnvironmentVariableType m_type; bool m_typeHasBeenSet = false; }; } // namespace Model } // namespace CodeBuild } // namespace Aws