/** * 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 namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace CloudWatchLogs { namespace Model { /** *

This structure contains information about one delivery destination in * your account. A delivery destination is an Amazon Web Services resource that * represents an Amazon Web Services service that logs can be sent to. CloudWatch * Logs, Amazon S3, are supported as Firehose delivery destinations.

To * configure logs delivery between a supported Amazon Web Services service and a * destination, you must do the following:

  • Create a delivery * source, which is a logical object that represents the resource that is actually * sending the logs. For more information, see PutDeliverySource.

    *
  • Create a delivery destination, which is a logical object * that represents the actual delivery destination.

  • If you are * delivering logs cross-account, you must use PutDeliveryDestinationPolicy * in the destination account to assign an IAM policy to the destination. This * policy allows delivery to that destination.

  • Create a * delivery by pairing exactly one delivery source and one delivery * destination. For more information, see CreateDelivery.

    *

You can configure a single delivery source to send logs to * multiple destinations by creating multiple deliveries. You can also create * multiple deliveries to configure multiple delivery sources to send logs to the * same delivery destination.

See Also:

AWS * API Reference

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

The name of this delivery destination.

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

The name of this delivery destination.

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

The name of this delivery destination.

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

The name of this delivery destination.

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

The name of this delivery destination.

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

The name of this delivery destination.

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

The name of this delivery destination.

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

The name of this delivery destination.

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

The Amazon Resource Name (ARN) that uniquely identifies this delivery * destination.

*/ inline const Aws::String& GetArn() const{ return m_arn; } /** *

The Amazon Resource Name (ARN) that uniquely identifies this delivery * destination.

*/ inline bool ArnHasBeenSet() const { return m_arnHasBeenSet; } /** *

The Amazon Resource Name (ARN) that uniquely identifies this delivery * destination.

*/ inline void SetArn(const Aws::String& value) { m_arnHasBeenSet = true; m_arn = value; } /** *

The Amazon Resource Name (ARN) that uniquely identifies this delivery * destination.

*/ inline void SetArn(Aws::String&& value) { m_arnHasBeenSet = true; m_arn = std::move(value); } /** *

The Amazon Resource Name (ARN) that uniquely identifies this delivery * destination.

*/ inline void SetArn(const char* value) { m_arnHasBeenSet = true; m_arn.assign(value); } /** *

The Amazon Resource Name (ARN) that uniquely identifies this delivery * destination.

*/ inline DeliveryDestination& WithArn(const Aws::String& value) { SetArn(value); return *this;} /** *

The Amazon Resource Name (ARN) that uniquely identifies this delivery * destination.

*/ inline DeliveryDestination& WithArn(Aws::String&& value) { SetArn(std::move(value)); return *this;} /** *

The Amazon Resource Name (ARN) that uniquely identifies this delivery * destination.

*/ inline DeliveryDestination& WithArn(const char* value) { SetArn(value); return *this;} /** *

Displays whether this delivery destination is CloudWatch Logs, Amazon S3, or * Firehose.

*/ inline const DeliveryDestinationType& GetDeliveryDestinationType() const{ return m_deliveryDestinationType; } /** *

Displays whether this delivery destination is CloudWatch Logs, Amazon S3, or * Firehose.

*/ inline bool DeliveryDestinationTypeHasBeenSet() const { return m_deliveryDestinationTypeHasBeenSet; } /** *

Displays whether this delivery destination is CloudWatch Logs, Amazon S3, or * Firehose.

*/ inline void SetDeliveryDestinationType(const DeliveryDestinationType& value) { m_deliveryDestinationTypeHasBeenSet = true; m_deliveryDestinationType = value; } /** *

Displays whether this delivery destination is CloudWatch Logs, Amazon S3, or * Firehose.

*/ inline void SetDeliveryDestinationType(DeliveryDestinationType&& value) { m_deliveryDestinationTypeHasBeenSet = true; m_deliveryDestinationType = std::move(value); } /** *

Displays whether this delivery destination is CloudWatch Logs, Amazon S3, or * Firehose.

*/ inline DeliveryDestination& WithDeliveryDestinationType(const DeliveryDestinationType& value) { SetDeliveryDestinationType(value); return *this;} /** *

Displays whether this delivery destination is CloudWatch Logs, Amazon S3, or * Firehose.

*/ inline DeliveryDestination& WithDeliveryDestinationType(DeliveryDestinationType&& value) { SetDeliveryDestinationType(std::move(value)); return *this;} /** *

The format of the logs that are sent to this delivery destination.

*/ inline const OutputFormat& GetOutputFormat() const{ return m_outputFormat; } /** *

The format of the logs that are sent to this delivery destination.

*/ inline bool OutputFormatHasBeenSet() const { return m_outputFormatHasBeenSet; } /** *

The format of the logs that are sent to this delivery destination.

*/ inline void SetOutputFormat(const OutputFormat& value) { m_outputFormatHasBeenSet = true; m_outputFormat = value; } /** *

The format of the logs that are sent to this delivery destination.

*/ inline void SetOutputFormat(OutputFormat&& value) { m_outputFormatHasBeenSet = true; m_outputFormat = std::move(value); } /** *

The format of the logs that are sent to this delivery destination.

*/ inline DeliveryDestination& WithOutputFormat(const OutputFormat& value) { SetOutputFormat(value); return *this;} /** *

The format of the logs that are sent to this delivery destination.

*/ inline DeliveryDestination& WithOutputFormat(OutputFormat&& value) { SetOutputFormat(std::move(value)); return *this;} /** *

A structure that contains the ARN of the Amazon Web Services resource that * will receive the logs.

*/ inline const DeliveryDestinationConfiguration& GetDeliveryDestinationConfiguration() const{ return m_deliveryDestinationConfiguration; } /** *

A structure that contains the ARN of the Amazon Web Services resource that * will receive the logs.

*/ inline bool DeliveryDestinationConfigurationHasBeenSet() const { return m_deliveryDestinationConfigurationHasBeenSet; } /** *

A structure that contains the ARN of the Amazon Web Services resource that * will receive the logs.

*/ inline void SetDeliveryDestinationConfiguration(const DeliveryDestinationConfiguration& value) { m_deliveryDestinationConfigurationHasBeenSet = true; m_deliveryDestinationConfiguration = value; } /** *

A structure that contains the ARN of the Amazon Web Services resource that * will receive the logs.

*/ inline void SetDeliveryDestinationConfiguration(DeliveryDestinationConfiguration&& value) { m_deliveryDestinationConfigurationHasBeenSet = true; m_deliveryDestinationConfiguration = std::move(value); } /** *

A structure that contains the ARN of the Amazon Web Services resource that * will receive the logs.

*/ inline DeliveryDestination& WithDeliveryDestinationConfiguration(const DeliveryDestinationConfiguration& value) { SetDeliveryDestinationConfiguration(value); return *this;} /** *

A structure that contains the ARN of the Amazon Web Services resource that * will receive the logs.

*/ inline DeliveryDestination& WithDeliveryDestinationConfiguration(DeliveryDestinationConfiguration&& value) { SetDeliveryDestinationConfiguration(std::move(value)); return *this;} /** *

The tags that have been assigned to this delivery destination.

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

The tags that have been assigned to this delivery destination.

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

The tags that have been assigned to this delivery destination.

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

The tags that have been assigned to this delivery destination.

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

The tags that have been assigned to this delivery destination.

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

The tags that have been assigned to this delivery destination.

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

The tags that have been assigned to this delivery destination.

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

The tags that have been assigned to this delivery destination.

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

The tags that have been assigned to this delivery destination.

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

The tags that have been assigned to this delivery destination.

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

The tags that have been assigned to this delivery destination.

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

The tags that have been assigned to this delivery destination.

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

The tags that have been assigned to this delivery destination.

*/ inline DeliveryDestination& AddTags(const char* key, const char* value) { m_tagsHasBeenSet = true; m_tags.emplace(key, value); return *this; } private: Aws::String m_name; bool m_nameHasBeenSet = false; Aws::String m_arn; bool m_arnHasBeenSet = false; DeliveryDestinationType m_deliveryDestinationType; bool m_deliveryDestinationTypeHasBeenSet = false; OutputFormat m_outputFormat; bool m_outputFormatHasBeenSet = false; DeliveryDestinationConfiguration m_deliveryDestinationConfiguration; bool m_deliveryDestinationConfigurationHasBeenSet = false; Aws::Map m_tags; bool m_tagsHasBeenSet = false; }; } // namespace Model } // namespace CloudWatchLogs } // namespace Aws