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

Specifies the default settings and content for a one-time email message * that's sent directly to an endpoint.

See Also:

AWS * API Reference

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

The body of the email message.

*/ inline const Aws::String& GetBody() const{ return m_body; } /** *

The body of the email message.

*/ inline bool BodyHasBeenSet() const { return m_bodyHasBeenSet; } /** *

The body of the email message.

*/ inline void SetBody(const Aws::String& value) { m_bodyHasBeenSet = true; m_body = value; } /** *

The body of the email message.

*/ inline void SetBody(Aws::String&& value) { m_bodyHasBeenSet = true; m_body = std::move(value); } /** *

The body of the email message.

*/ inline void SetBody(const char* value) { m_bodyHasBeenSet = true; m_body.assign(value); } /** *

The body of the email message.

*/ inline EmailMessage& WithBody(const Aws::String& value) { SetBody(value); return *this;} /** *

The body of the email message.

*/ inline EmailMessage& WithBody(Aws::String&& value) { SetBody(std::move(value)); return *this;} /** *

The body of the email message.

*/ inline EmailMessage& WithBody(const char* value) { SetBody(value); return *this;} /** *

The email address to forward bounces and complaints to, if feedback * forwarding is enabled.

*/ inline const Aws::String& GetFeedbackForwardingAddress() const{ return m_feedbackForwardingAddress; } /** *

The email address to forward bounces and complaints to, if feedback * forwarding is enabled.

*/ inline bool FeedbackForwardingAddressHasBeenSet() const { return m_feedbackForwardingAddressHasBeenSet; } /** *

The email address to forward bounces and complaints to, if feedback * forwarding is enabled.

*/ inline void SetFeedbackForwardingAddress(const Aws::String& value) { m_feedbackForwardingAddressHasBeenSet = true; m_feedbackForwardingAddress = value; } /** *

The email address to forward bounces and complaints to, if feedback * forwarding is enabled.

*/ inline void SetFeedbackForwardingAddress(Aws::String&& value) { m_feedbackForwardingAddressHasBeenSet = true; m_feedbackForwardingAddress = std::move(value); } /** *

The email address to forward bounces and complaints to, if feedback * forwarding is enabled.

*/ inline void SetFeedbackForwardingAddress(const char* value) { m_feedbackForwardingAddressHasBeenSet = true; m_feedbackForwardingAddress.assign(value); } /** *

The email address to forward bounces and complaints to, if feedback * forwarding is enabled.

*/ inline EmailMessage& WithFeedbackForwardingAddress(const Aws::String& value) { SetFeedbackForwardingAddress(value); return *this;} /** *

The email address to forward bounces and complaints to, if feedback * forwarding is enabled.

*/ inline EmailMessage& WithFeedbackForwardingAddress(Aws::String&& value) { SetFeedbackForwardingAddress(std::move(value)); return *this;} /** *

The email address to forward bounces and complaints to, if feedback * forwarding is enabled.

*/ inline EmailMessage& WithFeedbackForwardingAddress(const char* value) { SetFeedbackForwardingAddress(value); return *this;} /** *

The verified email address to send the email message from. The default value * is the FromAddress specified for the email channel.

*/ inline const Aws::String& GetFromAddress() const{ return m_fromAddress; } /** *

The verified email address to send the email message from. The default value * is the FromAddress specified for the email channel.

*/ inline bool FromAddressHasBeenSet() const { return m_fromAddressHasBeenSet; } /** *

The verified email address to send the email message from. The default value * is the FromAddress specified for the email channel.

*/ inline void SetFromAddress(const Aws::String& value) { m_fromAddressHasBeenSet = true; m_fromAddress = value; } /** *

The verified email address to send the email message from. The default value * is the FromAddress specified for the email channel.

*/ inline void SetFromAddress(Aws::String&& value) { m_fromAddressHasBeenSet = true; m_fromAddress = std::move(value); } /** *

The verified email address to send the email message from. The default value * is the FromAddress specified for the email channel.

*/ inline void SetFromAddress(const char* value) { m_fromAddressHasBeenSet = true; m_fromAddress.assign(value); } /** *

The verified email address to send the email message from. The default value * is the FromAddress specified for the email channel.

*/ inline EmailMessage& WithFromAddress(const Aws::String& value) { SetFromAddress(value); return *this;} /** *

The verified email address to send the email message from. The default value * is the FromAddress specified for the email channel.

*/ inline EmailMessage& WithFromAddress(Aws::String&& value) { SetFromAddress(std::move(value)); return *this;} /** *

The verified email address to send the email message from. The default value * is the FromAddress specified for the email channel.

*/ inline EmailMessage& WithFromAddress(const char* value) { SetFromAddress(value); return *this;} /** *

The email message, represented as a raw MIME message.

*/ inline const RawEmail& GetRawEmail() const{ return m_rawEmail; } /** *

The email message, represented as a raw MIME message.

*/ inline bool RawEmailHasBeenSet() const { return m_rawEmailHasBeenSet; } /** *

The email message, represented as a raw MIME message.

*/ inline void SetRawEmail(const RawEmail& value) { m_rawEmailHasBeenSet = true; m_rawEmail = value; } /** *

The email message, represented as a raw MIME message.

*/ inline void SetRawEmail(RawEmail&& value) { m_rawEmailHasBeenSet = true; m_rawEmail = std::move(value); } /** *

The email message, represented as a raw MIME message.

*/ inline EmailMessage& WithRawEmail(const RawEmail& value) { SetRawEmail(value); return *this;} /** *

The email message, represented as a raw MIME message.

*/ inline EmailMessage& WithRawEmail(RawEmail&& value) { SetRawEmail(std::move(value)); return *this;} /** *

The reply-to email address(es) for the email message. If a recipient replies * to the email, each reply-to address receives the reply.

*/ inline const Aws::Vector& GetReplyToAddresses() const{ return m_replyToAddresses; } /** *

The reply-to email address(es) for the email message. If a recipient replies * to the email, each reply-to address receives the reply.

*/ inline bool ReplyToAddressesHasBeenSet() const { return m_replyToAddressesHasBeenSet; } /** *

The reply-to email address(es) for the email message. If a recipient replies * to the email, each reply-to address receives the reply.

*/ inline void SetReplyToAddresses(const Aws::Vector& value) { m_replyToAddressesHasBeenSet = true; m_replyToAddresses = value; } /** *

The reply-to email address(es) for the email message. If a recipient replies * to the email, each reply-to address receives the reply.

*/ inline void SetReplyToAddresses(Aws::Vector&& value) { m_replyToAddressesHasBeenSet = true; m_replyToAddresses = std::move(value); } /** *

The reply-to email address(es) for the email message. If a recipient replies * to the email, each reply-to address receives the reply.

*/ inline EmailMessage& WithReplyToAddresses(const Aws::Vector& value) { SetReplyToAddresses(value); return *this;} /** *

The reply-to email address(es) for the email message. If a recipient replies * to the email, each reply-to address receives the reply.

*/ inline EmailMessage& WithReplyToAddresses(Aws::Vector&& value) { SetReplyToAddresses(std::move(value)); return *this;} /** *

The reply-to email address(es) for the email message. If a recipient replies * to the email, each reply-to address receives the reply.

*/ inline EmailMessage& AddReplyToAddresses(const Aws::String& value) { m_replyToAddressesHasBeenSet = true; m_replyToAddresses.push_back(value); return *this; } /** *

The reply-to email address(es) for the email message. If a recipient replies * to the email, each reply-to address receives the reply.

*/ inline EmailMessage& AddReplyToAddresses(Aws::String&& value) { m_replyToAddressesHasBeenSet = true; m_replyToAddresses.push_back(std::move(value)); return *this; } /** *

The reply-to email address(es) for the email message. If a recipient replies * to the email, each reply-to address receives the reply.

*/ inline EmailMessage& AddReplyToAddresses(const char* value) { m_replyToAddressesHasBeenSet = true; m_replyToAddresses.push_back(value); return *this; } /** *

The email message, composed of a subject, a text part, and an HTML part.

*/ inline const SimpleEmail& GetSimpleEmail() const{ return m_simpleEmail; } /** *

The email message, composed of a subject, a text part, and an HTML part.

*/ inline bool SimpleEmailHasBeenSet() const { return m_simpleEmailHasBeenSet; } /** *

The email message, composed of a subject, a text part, and an HTML part.

*/ inline void SetSimpleEmail(const SimpleEmail& value) { m_simpleEmailHasBeenSet = true; m_simpleEmail = value; } /** *

The email message, composed of a subject, a text part, and an HTML part.

*/ inline void SetSimpleEmail(SimpleEmail&& value) { m_simpleEmailHasBeenSet = true; m_simpleEmail = std::move(value); } /** *

The email message, composed of a subject, a text part, and an HTML part.

*/ inline EmailMessage& WithSimpleEmail(const SimpleEmail& value) { SetSimpleEmail(value); return *this;} /** *

The email message, composed of a subject, a text part, and an HTML part.

*/ inline EmailMessage& WithSimpleEmail(SimpleEmail&& value) { SetSimpleEmail(std::move(value)); return *this;} /** *

The default message variables to use in the email message. You can override * the default variables with individual address variables.

*/ inline const Aws::Map>& GetSubstitutions() const{ return m_substitutions; } /** *

The default message variables to use in the email message. You can override * the default variables with individual address variables.

*/ inline bool SubstitutionsHasBeenSet() const { return m_substitutionsHasBeenSet; } /** *

The default message variables to use in the email message. You can override * the default variables with individual address variables.

*/ inline void SetSubstitutions(const Aws::Map>& value) { m_substitutionsHasBeenSet = true; m_substitutions = value; } /** *

The default message variables to use in the email message. You can override * the default variables with individual address variables.

*/ inline void SetSubstitutions(Aws::Map>&& value) { m_substitutionsHasBeenSet = true; m_substitutions = std::move(value); } /** *

The default message variables to use in the email message. You can override * the default variables with individual address variables.

*/ inline EmailMessage& WithSubstitutions(const Aws::Map>& value) { SetSubstitutions(value); return *this;} /** *

The default message variables to use in the email message. You can override * the default variables with individual address variables.

*/ inline EmailMessage& WithSubstitutions(Aws::Map>&& value) { SetSubstitutions(std::move(value)); return *this;} /** *

The default message variables to use in the email message. You can override * the default variables with individual address variables.

*/ inline EmailMessage& AddSubstitutions(const Aws::String& key, const Aws::Vector& value) { m_substitutionsHasBeenSet = true; m_substitutions.emplace(key, value); return *this; } /** *

The default message variables to use in the email message. You can override * the default variables with individual address variables.

*/ inline EmailMessage& AddSubstitutions(Aws::String&& key, const Aws::Vector& value) { m_substitutionsHasBeenSet = true; m_substitutions.emplace(std::move(key), value); return *this; } /** *

The default message variables to use in the email message. You can override * the default variables with individual address variables.

*/ inline EmailMessage& AddSubstitutions(const Aws::String& key, Aws::Vector&& value) { m_substitutionsHasBeenSet = true; m_substitutions.emplace(key, std::move(value)); return *this; } /** *

The default message variables to use in the email message. You can override * the default variables with individual address variables.

*/ inline EmailMessage& AddSubstitutions(Aws::String&& key, Aws::Vector&& value) { m_substitutionsHasBeenSet = true; m_substitutions.emplace(std::move(key), std::move(value)); return *this; } /** *

The default message variables to use in the email message. You can override * the default variables with individual address variables.

*/ inline EmailMessage& AddSubstitutions(const char* key, Aws::Vector&& value) { m_substitutionsHasBeenSet = true; m_substitutions.emplace(key, std::move(value)); return *this; } /** *

The default message variables to use in the email message. You can override * the default variables with individual address variables.

*/ inline EmailMessage& AddSubstitutions(const char* key, const Aws::Vector& value) { m_substitutionsHasBeenSet = true; m_substitutions.emplace(key, value); return *this; } private: Aws::String m_body; bool m_bodyHasBeenSet = false; Aws::String m_feedbackForwardingAddress; bool m_feedbackForwardingAddressHasBeenSet = false; Aws::String m_fromAddress; bool m_fromAddressHasBeenSet = false; RawEmail m_rawEmail; bool m_rawEmailHasBeenSet = false; Aws::Vector m_replyToAddresses; bool m_replyToAddressesHasBeenSet = false; SimpleEmail m_simpleEmail; bool m_simpleEmailHasBeenSet = false; Aws::Map> m_substitutions; bool m_substitutionsHasBeenSet = false; }; } // namespace Model } // namespace Pinpoint } // namespace Aws