/** * 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 Utils { namespace Xml { class XmlNode; } // namespace Xml } // namespace Utils namespace ElastiCache { namespace Model { /** *

Returns the destination, format and type of the logs.

See * Also:

AWS * API Reference

*/ class LogDeliveryConfiguration { public: AWS_ELASTICACHE_API LogDeliveryConfiguration(); AWS_ELASTICACHE_API LogDeliveryConfiguration(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_ELASTICACHE_API LogDeliveryConfiguration& operator=(const Aws::Utils::Xml::XmlNode& xmlNode); AWS_ELASTICACHE_API void OutputToStream(Aws::OStream& ostream, const char* location, unsigned index, const char* locationValue) const; AWS_ELASTICACHE_API void OutputToStream(Aws::OStream& oStream, const char* location) const; /** *

Refers to slow-log or * engine-log.

*/ inline const LogType& GetLogType() const{ return m_logType; } /** *

Refers to slow-log or * engine-log.

*/ inline bool LogTypeHasBeenSet() const { return m_logTypeHasBeenSet; } /** *

Refers to slow-log or * engine-log.

*/ inline void SetLogType(const LogType& value) { m_logTypeHasBeenSet = true; m_logType = value; } /** *

Refers to slow-log or * engine-log.

*/ inline void SetLogType(LogType&& value) { m_logTypeHasBeenSet = true; m_logType = std::move(value); } /** *

Refers to slow-log or * engine-log.

*/ inline LogDeliveryConfiguration& WithLogType(const LogType& value) { SetLogType(value); return *this;} /** *

Refers to slow-log or * engine-log.

*/ inline LogDeliveryConfiguration& WithLogType(LogType&& value) { SetLogType(std::move(value)); return *this;} /** *

Returns the destination type, either cloudwatch-logs or * kinesis-firehose.

*/ inline const DestinationType& GetDestinationType() const{ return m_destinationType; } /** *

Returns the destination type, either cloudwatch-logs or * kinesis-firehose.

*/ inline bool DestinationTypeHasBeenSet() const { return m_destinationTypeHasBeenSet; } /** *

Returns the destination type, either cloudwatch-logs or * kinesis-firehose.

*/ inline void SetDestinationType(const DestinationType& value) { m_destinationTypeHasBeenSet = true; m_destinationType = value; } /** *

Returns the destination type, either cloudwatch-logs or * kinesis-firehose.

*/ inline void SetDestinationType(DestinationType&& value) { m_destinationTypeHasBeenSet = true; m_destinationType = std::move(value); } /** *

Returns the destination type, either cloudwatch-logs or * kinesis-firehose.

*/ inline LogDeliveryConfiguration& WithDestinationType(const DestinationType& value) { SetDestinationType(value); return *this;} /** *

Returns the destination type, either cloudwatch-logs or * kinesis-firehose.

*/ inline LogDeliveryConfiguration& WithDestinationType(DestinationType&& value) { SetDestinationType(std::move(value)); return *this;} /** *

Configuration details of either a CloudWatch Logs destination or Kinesis Data * Firehose destination.

*/ inline const DestinationDetails& GetDestinationDetails() const{ return m_destinationDetails; } /** *

Configuration details of either a CloudWatch Logs destination or Kinesis Data * Firehose destination.

*/ inline bool DestinationDetailsHasBeenSet() const { return m_destinationDetailsHasBeenSet; } /** *

Configuration details of either a CloudWatch Logs destination or Kinesis Data * Firehose destination.

*/ inline void SetDestinationDetails(const DestinationDetails& value) { m_destinationDetailsHasBeenSet = true; m_destinationDetails = value; } /** *

Configuration details of either a CloudWatch Logs destination or Kinesis Data * Firehose destination.

*/ inline void SetDestinationDetails(DestinationDetails&& value) { m_destinationDetailsHasBeenSet = true; m_destinationDetails = std::move(value); } /** *

Configuration details of either a CloudWatch Logs destination or Kinesis Data * Firehose destination.

*/ inline LogDeliveryConfiguration& WithDestinationDetails(const DestinationDetails& value) { SetDestinationDetails(value); return *this;} /** *

Configuration details of either a CloudWatch Logs destination or Kinesis Data * Firehose destination.

*/ inline LogDeliveryConfiguration& WithDestinationDetails(DestinationDetails&& value) { SetDestinationDetails(std::move(value)); return *this;} /** *

Returns the log format, either JSON or TEXT.

*/ inline const LogFormat& GetLogFormat() const{ return m_logFormat; } /** *

Returns the log format, either JSON or TEXT.

*/ inline bool LogFormatHasBeenSet() const { return m_logFormatHasBeenSet; } /** *

Returns the log format, either JSON or TEXT.

*/ inline void SetLogFormat(const LogFormat& value) { m_logFormatHasBeenSet = true; m_logFormat = value; } /** *

Returns the log format, either JSON or TEXT.

*/ inline void SetLogFormat(LogFormat&& value) { m_logFormatHasBeenSet = true; m_logFormat = std::move(value); } /** *

Returns the log format, either JSON or TEXT.

*/ inline LogDeliveryConfiguration& WithLogFormat(const LogFormat& value) { SetLogFormat(value); return *this;} /** *

Returns the log format, either JSON or TEXT.

*/ inline LogDeliveryConfiguration& WithLogFormat(LogFormat&& value) { SetLogFormat(std::move(value)); return *this;} /** *

Returns the log delivery configuration status. Values are one of * enabling | disabling | modifying | * active | error

*/ inline const LogDeliveryConfigurationStatus& GetStatus() const{ return m_status; } /** *

Returns the log delivery configuration status. Values are one of * enabling | disabling | modifying | * active | error

*/ inline bool StatusHasBeenSet() const { return m_statusHasBeenSet; } /** *

Returns the log delivery configuration status. Values are one of * enabling | disabling | modifying | * active | error

*/ inline void SetStatus(const LogDeliveryConfigurationStatus& value) { m_statusHasBeenSet = true; m_status = value; } /** *

Returns the log delivery configuration status. Values are one of * enabling | disabling | modifying | * active | error

*/ inline void SetStatus(LogDeliveryConfigurationStatus&& value) { m_statusHasBeenSet = true; m_status = std::move(value); } /** *

Returns the log delivery configuration status. Values are one of * enabling | disabling | modifying | * active | error

*/ inline LogDeliveryConfiguration& WithStatus(const LogDeliveryConfigurationStatus& value) { SetStatus(value); return *this;} /** *

Returns the log delivery configuration status. Values are one of * enabling | disabling | modifying | * active | error

*/ inline LogDeliveryConfiguration& WithStatus(LogDeliveryConfigurationStatus&& value) { SetStatus(std::move(value)); return *this;} /** *

Returns an error message for the log delivery configuration.

*/ inline const Aws::String& GetMessage() const{ return m_message; } /** *

Returns an error message for the log delivery configuration.

*/ inline bool MessageHasBeenSet() const { return m_messageHasBeenSet; } /** *

Returns an error message for the log delivery configuration.

*/ inline void SetMessage(const Aws::String& value) { m_messageHasBeenSet = true; m_message = value; } /** *

Returns an error message for the log delivery configuration.

*/ inline void SetMessage(Aws::String&& value) { m_messageHasBeenSet = true; m_message = std::move(value); } /** *

Returns an error message for the log delivery configuration.

*/ inline void SetMessage(const char* value) { m_messageHasBeenSet = true; m_message.assign(value); } /** *

Returns an error message for the log delivery configuration.

*/ inline LogDeliveryConfiguration& WithMessage(const Aws::String& value) { SetMessage(value); return *this;} /** *

Returns an error message for the log delivery configuration.

*/ inline LogDeliveryConfiguration& WithMessage(Aws::String&& value) { SetMessage(std::move(value)); return *this;} /** *

Returns an error message for the log delivery configuration.

*/ inline LogDeliveryConfiguration& WithMessage(const char* value) { SetMessage(value); return *this;} private: LogType m_logType; bool m_logTypeHasBeenSet = false; DestinationType m_destinationType; bool m_destinationTypeHasBeenSet = false; DestinationDetails m_destinationDetails; bool m_destinationDetailsHasBeenSet = false; LogFormat m_logFormat; bool m_logFormatHasBeenSet = false; LogDeliveryConfigurationStatus m_status; bool m_statusHasBeenSet = false; Aws::String m_message; bool m_messageHasBeenSet = false; }; } // namespace Model } // namespace ElastiCache } // namespace Aws