/** * 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 Redshift { namespace Model { /** *

See Also:

AWS * API Reference

*/ class EnableLoggingRequest : public RedshiftRequest { public: AWS_REDSHIFT_API EnableLoggingRequest(); // 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 "EnableLogging"; } AWS_REDSHIFT_API Aws::String SerializePayload() const override; protected: AWS_REDSHIFT_API void DumpBodyToUrl(Aws::Http::URI& uri ) const override; public: /** *

The identifier of the cluster on which logging is to be started.

*

Example: examplecluster

*/ inline const Aws::String& GetClusterIdentifier() const{ return m_clusterIdentifier; } /** *

The identifier of the cluster on which logging is to be started.

*

Example: examplecluster

*/ inline bool ClusterIdentifierHasBeenSet() const { return m_clusterIdentifierHasBeenSet; } /** *

The identifier of the cluster on which logging is to be started.

*

Example: examplecluster

*/ inline void SetClusterIdentifier(const Aws::String& value) { m_clusterIdentifierHasBeenSet = true; m_clusterIdentifier = value; } /** *

The identifier of the cluster on which logging is to be started.

*

Example: examplecluster

*/ inline void SetClusterIdentifier(Aws::String&& value) { m_clusterIdentifierHasBeenSet = true; m_clusterIdentifier = std::move(value); } /** *

The identifier of the cluster on which logging is to be started.

*

Example: examplecluster

*/ inline void SetClusterIdentifier(const char* value) { m_clusterIdentifierHasBeenSet = true; m_clusterIdentifier.assign(value); } /** *

The identifier of the cluster on which logging is to be started.

*

Example: examplecluster

*/ inline EnableLoggingRequest& WithClusterIdentifier(const Aws::String& value) { SetClusterIdentifier(value); return *this;} /** *

The identifier of the cluster on which logging is to be started.

*

Example: examplecluster

*/ inline EnableLoggingRequest& WithClusterIdentifier(Aws::String&& value) { SetClusterIdentifier(std::move(value)); return *this;} /** *

The identifier of the cluster on which logging is to be started.

*

Example: examplecluster

*/ inline EnableLoggingRequest& WithClusterIdentifier(const char* value) { SetClusterIdentifier(value); return *this;} /** *

The name of an existing S3 bucket where the log files are to be stored.

*

Constraints:

  • Must be in the same region as the cluster

    *
  • The cluster must have read bucket and put object permissions

    *
*/ inline const Aws::String& GetBucketName() const{ return m_bucketName; } /** *

The name of an existing S3 bucket where the log files are to be stored.

*

Constraints:

  • Must be in the same region as the cluster

    *
  • The cluster must have read bucket and put object permissions

    *
*/ inline bool BucketNameHasBeenSet() const { return m_bucketNameHasBeenSet; } /** *

The name of an existing S3 bucket where the log files are to be stored.

*

Constraints:

  • Must be in the same region as the cluster

    *
  • The cluster must have read bucket and put object permissions

    *
*/ inline void SetBucketName(const Aws::String& value) { m_bucketNameHasBeenSet = true; m_bucketName = value; } /** *

The name of an existing S3 bucket where the log files are to be stored.

*

Constraints:

  • Must be in the same region as the cluster

    *
  • The cluster must have read bucket and put object permissions

    *
*/ inline void SetBucketName(Aws::String&& value) { m_bucketNameHasBeenSet = true; m_bucketName = std::move(value); } /** *

The name of an existing S3 bucket where the log files are to be stored.

*

Constraints:

  • Must be in the same region as the cluster

    *
  • The cluster must have read bucket and put object permissions

    *
*/ inline void SetBucketName(const char* value) { m_bucketNameHasBeenSet = true; m_bucketName.assign(value); } /** *

The name of an existing S3 bucket where the log files are to be stored.

*

Constraints:

  • Must be in the same region as the cluster

    *
  • The cluster must have read bucket and put object permissions

    *
*/ inline EnableLoggingRequest& WithBucketName(const Aws::String& value) { SetBucketName(value); return *this;} /** *

The name of an existing S3 bucket where the log files are to be stored.

*

Constraints:

  • Must be in the same region as the cluster

    *
  • The cluster must have read bucket and put object permissions

    *
*/ inline EnableLoggingRequest& WithBucketName(Aws::String&& value) { SetBucketName(std::move(value)); return *this;} /** *

The name of an existing S3 bucket where the log files are to be stored.

*

Constraints:

  • Must be in the same region as the cluster

    *
  • The cluster must have read bucket and put object permissions

    *
*/ inline EnableLoggingRequest& WithBucketName(const char* value) { SetBucketName(value); return *this;} /** *

The prefix applied to the log file names.

Constraints:

  • *

    Cannot exceed 512 characters

  • Cannot contain spaces( ), * double quotes ("), single quotes ('), a backslash (\), or control characters. * The hexadecimal codes for invalid characters are:

    • x00 to * x20

    • x22

    • x27

    • x5c

    • *
    • x7f or larger

*/ inline const Aws::String& GetS3KeyPrefix() const{ return m_s3KeyPrefix; } /** *

The prefix applied to the log file names.

Constraints:

  • *

    Cannot exceed 512 characters

  • Cannot contain spaces( ), * double quotes ("), single quotes ('), a backslash (\), or control characters. * The hexadecimal codes for invalid characters are:

    • x00 to * x20

    • x22

    • x27

    • x5c

    • *
    • x7f or larger

*/ inline bool S3KeyPrefixHasBeenSet() const { return m_s3KeyPrefixHasBeenSet; } /** *

The prefix applied to the log file names.

Constraints:

  • *

    Cannot exceed 512 characters

  • Cannot contain spaces( ), * double quotes ("), single quotes ('), a backslash (\), or control characters. * The hexadecimal codes for invalid characters are:

    • x00 to * x20

    • x22

    • x27

    • x5c

    • *
    • x7f or larger

*/ inline void SetS3KeyPrefix(const Aws::String& value) { m_s3KeyPrefixHasBeenSet = true; m_s3KeyPrefix = value; } /** *

The prefix applied to the log file names.

Constraints:

  • *

    Cannot exceed 512 characters

  • Cannot contain spaces( ), * double quotes ("), single quotes ('), a backslash (\), or control characters. * The hexadecimal codes for invalid characters are:

    • x00 to * x20

    • x22

    • x27

    • x5c

    • *
    • x7f or larger

*/ inline void SetS3KeyPrefix(Aws::String&& value) { m_s3KeyPrefixHasBeenSet = true; m_s3KeyPrefix = std::move(value); } /** *

The prefix applied to the log file names.

Constraints:

  • *

    Cannot exceed 512 characters

  • Cannot contain spaces( ), * double quotes ("), single quotes ('), a backslash (\), or control characters. * The hexadecimal codes for invalid characters are:

    • x00 to * x20

    • x22

    • x27

    • x5c

    • *
    • x7f or larger

*/ inline void SetS3KeyPrefix(const char* value) { m_s3KeyPrefixHasBeenSet = true; m_s3KeyPrefix.assign(value); } /** *

The prefix applied to the log file names.

Constraints:

  • *

    Cannot exceed 512 characters

  • Cannot contain spaces( ), * double quotes ("), single quotes ('), a backslash (\), or control characters. * The hexadecimal codes for invalid characters are:

    • x00 to * x20

    • x22

    • x27

    • x5c

    • *
    • x7f or larger

*/ inline EnableLoggingRequest& WithS3KeyPrefix(const Aws::String& value) { SetS3KeyPrefix(value); return *this;} /** *

The prefix applied to the log file names.

Constraints:

  • *

    Cannot exceed 512 characters

  • Cannot contain spaces( ), * double quotes ("), single quotes ('), a backslash (\), or control characters. * The hexadecimal codes for invalid characters are:

    • x00 to * x20

    • x22

    • x27

    • x5c

    • *
    • x7f or larger

*/ inline EnableLoggingRequest& WithS3KeyPrefix(Aws::String&& value) { SetS3KeyPrefix(std::move(value)); return *this;} /** *

The prefix applied to the log file names.

Constraints:

  • *

    Cannot exceed 512 characters

  • Cannot contain spaces( ), * double quotes ("), single quotes ('), a backslash (\), or control characters. * The hexadecimal codes for invalid characters are:

    • x00 to * x20

    • x22

    • x27

    • x5c

    • *
    • x7f or larger

*/ inline EnableLoggingRequest& WithS3KeyPrefix(const char* value) { SetS3KeyPrefix(value); return *this;} /** *

The log destination type. An enum with possible values of s3 and * cloudwatch.

*/ inline const LogDestinationType& GetLogDestinationType() const{ return m_logDestinationType; } /** *

The log destination type. An enum with possible values of s3 and * cloudwatch.

*/ inline bool LogDestinationTypeHasBeenSet() const { return m_logDestinationTypeHasBeenSet; } /** *

The log destination type. An enum with possible values of s3 and * cloudwatch.

*/ inline void SetLogDestinationType(const LogDestinationType& value) { m_logDestinationTypeHasBeenSet = true; m_logDestinationType = value; } /** *

The log destination type. An enum with possible values of s3 and * cloudwatch.

*/ inline void SetLogDestinationType(LogDestinationType&& value) { m_logDestinationTypeHasBeenSet = true; m_logDestinationType = std::move(value); } /** *

The log destination type. An enum with possible values of s3 and * cloudwatch.

*/ inline EnableLoggingRequest& WithLogDestinationType(const LogDestinationType& value) { SetLogDestinationType(value); return *this;} /** *

The log destination type. An enum with possible values of s3 and * cloudwatch.

*/ inline EnableLoggingRequest& WithLogDestinationType(LogDestinationType&& value) { SetLogDestinationType(std::move(value)); return *this;} /** *

The collection of exported log types. Possible values are * connectionlog, useractivitylog, and * userlog.

*/ inline const Aws::Vector& GetLogExports() const{ return m_logExports; } /** *

The collection of exported log types. Possible values are * connectionlog, useractivitylog, and * userlog.

*/ inline bool LogExportsHasBeenSet() const { return m_logExportsHasBeenSet; } /** *

The collection of exported log types. Possible values are * connectionlog, useractivitylog, and * userlog.

*/ inline void SetLogExports(const Aws::Vector& value) { m_logExportsHasBeenSet = true; m_logExports = value; } /** *

The collection of exported log types. Possible values are * connectionlog, useractivitylog, and * userlog.

*/ inline void SetLogExports(Aws::Vector&& value) { m_logExportsHasBeenSet = true; m_logExports = std::move(value); } /** *

The collection of exported log types. Possible values are * connectionlog, useractivitylog, and * userlog.

*/ inline EnableLoggingRequest& WithLogExports(const Aws::Vector& value) { SetLogExports(value); return *this;} /** *

The collection of exported log types. Possible values are * connectionlog, useractivitylog, and * userlog.

*/ inline EnableLoggingRequest& WithLogExports(Aws::Vector&& value) { SetLogExports(std::move(value)); return *this;} /** *

The collection of exported log types. Possible values are * connectionlog, useractivitylog, and * userlog.

*/ inline EnableLoggingRequest& AddLogExports(const Aws::String& value) { m_logExportsHasBeenSet = true; m_logExports.push_back(value); return *this; } /** *

The collection of exported log types. Possible values are * connectionlog, useractivitylog, and * userlog.

*/ inline EnableLoggingRequest& AddLogExports(Aws::String&& value) { m_logExportsHasBeenSet = true; m_logExports.push_back(std::move(value)); return *this; } /** *

The collection of exported log types. Possible values are * connectionlog, useractivitylog, and * userlog.

*/ inline EnableLoggingRequest& AddLogExports(const char* value) { m_logExportsHasBeenSet = true; m_logExports.push_back(value); return *this; } private: Aws::String m_clusterIdentifier; bool m_clusterIdentifierHasBeenSet = false; Aws::String m_bucketName; bool m_bucketNameHasBeenSet = false; Aws::String m_s3KeyPrefix; bool m_s3KeyPrefixHasBeenSet = false; LogDestinationType m_logDestinationType; bool m_logDestinationTypeHasBeenSet = false; Aws::Vector m_logExports; bool m_logExportsHasBeenSet = false; }; } // namespace Model } // namespace Redshift } // namespace Aws