/**
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
* SPDX-License-Identifier: Apache-2.0.
*/
#pragma once
#include Describes the access log configuration for a bucket in the Amazon Lightsail
* object storage service. For more information about bucket access logs,
* see Logging
* bucket requests using access logging in Amazon Lightsail in the Amazon
* Lightsail Developer Guide.See Also:
AWS
* API Reference
A Boolean value that indicates whether bucket access logging is enabled for * the bucket.
*/ inline bool GetEnabled() const{ return m_enabled; } /** *A Boolean value that indicates whether bucket access logging is enabled for * the bucket.
*/ inline bool EnabledHasBeenSet() const { return m_enabledHasBeenSet; } /** *A Boolean value that indicates whether bucket access logging is enabled for * the bucket.
*/ inline void SetEnabled(bool value) { m_enabledHasBeenSet = true; m_enabled = value; } /** *A Boolean value that indicates whether bucket access logging is enabled for * the bucket.
*/ inline BucketAccessLogConfig& WithEnabled(bool value) { SetEnabled(value); return *this;} /** *The name of the bucket where the access logs are saved. The destination can * be a Lightsail bucket in the same account, and in the same Amazon Web Services * Region as the source bucket.
This parameter is required when * enabling the access log for a bucket, and should be omitted when disabling the * access log.
*/ inline const Aws::String& GetDestination() const{ return m_destination; } /** *The name of the bucket where the access logs are saved. The destination can * be a Lightsail bucket in the same account, and in the same Amazon Web Services * Region as the source bucket.
This parameter is required when * enabling the access log for a bucket, and should be omitted when disabling the * access log.
*/ inline bool DestinationHasBeenSet() const { return m_destinationHasBeenSet; } /** *The name of the bucket where the access logs are saved. The destination can * be a Lightsail bucket in the same account, and in the same Amazon Web Services * Region as the source bucket.
This parameter is required when * enabling the access log for a bucket, and should be omitted when disabling the * access log.
*/ inline void SetDestination(const Aws::String& value) { m_destinationHasBeenSet = true; m_destination = value; } /** *The name of the bucket where the access logs are saved. The destination can * be a Lightsail bucket in the same account, and in the same Amazon Web Services * Region as the source bucket.
This parameter is required when * enabling the access log for a bucket, and should be omitted when disabling the * access log.
*/ inline void SetDestination(Aws::String&& value) { m_destinationHasBeenSet = true; m_destination = std::move(value); } /** *The name of the bucket where the access logs are saved. The destination can * be a Lightsail bucket in the same account, and in the same Amazon Web Services * Region as the source bucket.
This parameter is required when * enabling the access log for a bucket, and should be omitted when disabling the * access log.
*/ inline void SetDestination(const char* value) { m_destinationHasBeenSet = true; m_destination.assign(value); } /** *The name of the bucket where the access logs are saved. The destination can * be a Lightsail bucket in the same account, and in the same Amazon Web Services * Region as the source bucket.
This parameter is required when * enabling the access log for a bucket, and should be omitted when disabling the * access log.
*/ inline BucketAccessLogConfig& WithDestination(const Aws::String& value) { SetDestination(value); return *this;} /** *The name of the bucket where the access logs are saved. The destination can * be a Lightsail bucket in the same account, and in the same Amazon Web Services * Region as the source bucket.
This parameter is required when * enabling the access log for a bucket, and should be omitted when disabling the * access log.
*/ inline BucketAccessLogConfig& WithDestination(Aws::String&& value) { SetDestination(std::move(value)); return *this;} /** *The name of the bucket where the access logs are saved. The destination can * be a Lightsail bucket in the same account, and in the same Amazon Web Services * Region as the source bucket.
This parameter is required when * enabling the access log for a bucket, and should be omitted when disabling the * access log.
*/ inline BucketAccessLogConfig& WithDestination(const char* value) { SetDestination(value); return *this;} /** *The optional object prefix for the bucket access log.
The prefix is an
* optional addition to the object key that organizes your access log files in the
* destination bucket. For example, if you specify a logs/
prefix,
* then each log object will begin with the logs/
prefix in its key
* (for example, logs/2021-11-01-21-32-16-E568B2907131C0C0
).
This parameter can be optionally specified when enabling the access * log for a bucket, and should be omitted when disabling the access log.
* */ inline const Aws::String& GetPrefix() const{ return m_prefix; } /** *The optional object prefix for the bucket access log.
The prefix is an
* optional addition to the object key that organizes your access log files in the
* destination bucket. For example, if you specify a logs/
prefix,
* then each log object will begin with the logs/
prefix in its key
* (for example, logs/2021-11-01-21-32-16-E568B2907131C0C0
).
This parameter can be optionally specified when enabling the access * log for a bucket, and should be omitted when disabling the access log.
* */ inline bool PrefixHasBeenSet() const { return m_prefixHasBeenSet; } /** *The optional object prefix for the bucket access log.
The prefix is an
* optional addition to the object key that organizes your access log files in the
* destination bucket. For example, if you specify a logs/
prefix,
* then each log object will begin with the logs/
prefix in its key
* (for example, logs/2021-11-01-21-32-16-E568B2907131C0C0
).
This parameter can be optionally specified when enabling the access * log for a bucket, and should be omitted when disabling the access log.
* */ inline void SetPrefix(const Aws::String& value) { m_prefixHasBeenSet = true; m_prefix = value; } /** *The optional object prefix for the bucket access log.
The prefix is an
* optional addition to the object key that organizes your access log files in the
* destination bucket. For example, if you specify a logs/
prefix,
* then each log object will begin with the logs/
prefix in its key
* (for example, logs/2021-11-01-21-32-16-E568B2907131C0C0
).
This parameter can be optionally specified when enabling the access * log for a bucket, and should be omitted when disabling the access log.
* */ inline void SetPrefix(Aws::String&& value) { m_prefixHasBeenSet = true; m_prefix = std::move(value); } /** *The optional object prefix for the bucket access log.
The prefix is an
* optional addition to the object key that organizes your access log files in the
* destination bucket. For example, if you specify a logs/
prefix,
* then each log object will begin with the logs/
prefix in its key
* (for example, logs/2021-11-01-21-32-16-E568B2907131C0C0
).
This parameter can be optionally specified when enabling the access * log for a bucket, and should be omitted when disabling the access log.
* */ inline void SetPrefix(const char* value) { m_prefixHasBeenSet = true; m_prefix.assign(value); } /** *The optional object prefix for the bucket access log.
The prefix is an
* optional addition to the object key that organizes your access log files in the
* destination bucket. For example, if you specify a logs/
prefix,
* then each log object will begin with the logs/
prefix in its key
* (for example, logs/2021-11-01-21-32-16-E568B2907131C0C0
).
This parameter can be optionally specified when enabling the access * log for a bucket, and should be omitted when disabling the access log.
* */ inline BucketAccessLogConfig& WithPrefix(const Aws::String& value) { SetPrefix(value); return *this;} /** *The optional object prefix for the bucket access log.
The prefix is an
* optional addition to the object key that organizes your access log files in the
* destination bucket. For example, if you specify a logs/
prefix,
* then each log object will begin with the logs/
prefix in its key
* (for example, logs/2021-11-01-21-32-16-E568B2907131C0C0
).
This parameter can be optionally specified when enabling the access * log for a bucket, and should be omitted when disabling the access log.
* */ inline BucketAccessLogConfig& WithPrefix(Aws::String&& value) { SetPrefix(std::move(value)); return *this;} /** *The optional object prefix for the bucket access log.
The prefix is an
* optional addition to the object key that organizes your access log files in the
* destination bucket. For example, if you specify a logs/
prefix,
* then each log object will begin with the logs/
prefix in its key
* (for example, logs/2021-11-01-21-32-16-E568B2907131C0C0
).
This parameter can be optionally specified when enabling the access * log for a bucket, and should be omitted when disabling the access log.
* */ inline BucketAccessLogConfig& WithPrefix(const char* value) { SetPrefix(value); return *this;} private: bool m_enabled; bool m_enabledHasBeenSet = false; Aws::String m_destination; bool m_destinationHasBeenSet = false; Aws::String m_prefix; bool m_prefixHasBeenSet = false; }; } // namespace Model } // namespace Lightsail } // namespace Aws