AWS SDK for C++  1.9.1
AWS SDK for C++
SendMessageRequest.h
Go to the documentation of this file.
1 
6 #pragma once
7 #include <aws/sqs/SQS_EXPORTS.h>
8 #include <aws/sqs/SQSRequest.h>
14 #include <utility>
15 
16 namespace Aws
17 {
18 namespace SQS
19 {
20 namespace Model
21 {
22 
29  {
30  public:
32 
33  // Service request name is the Operation name which will send this request out,
34  // each operation should has unique request name, so that we can get operation's name from this request.
35  // Note: this is not true for response, multiple operations may have the same response name,
36  // so we can not get operation's name from response.
37  inline virtual const char* GetServiceRequestName() const override { return "SendMessage"; }
38 
39  Aws::String SerializePayload() const override;
40 
41  protected:
42  void DumpBodyToUrl(Aws::Http::URI& uri ) const override;
43 
44  public:
45 
50  inline const Aws::String& GetQueueUrl() const{ return m_queueUrl; }
51 
56  inline bool QueueUrlHasBeenSet() const { return m_queueUrlHasBeenSet; }
57 
62  inline void SetQueueUrl(const Aws::String& value) { m_queueUrlHasBeenSet = true; m_queueUrl = value; }
63 
68  inline void SetQueueUrl(Aws::String&& value) { m_queueUrlHasBeenSet = true; m_queueUrl = std::move(value); }
69 
74  inline void SetQueueUrl(const char* value) { m_queueUrlHasBeenSet = true; m_queueUrl.assign(value); }
75 
80  inline SendMessageRequest& WithQueueUrl(const Aws::String& value) { SetQueueUrl(value); return *this;}
81 
86  inline SendMessageRequest& WithQueueUrl(Aws::String&& value) { SetQueueUrl(std::move(value)); return *this;}
87 
92  inline SendMessageRequest& WithQueueUrl(const char* value) { SetQueueUrl(value); return *this;}
93 
94 
106  inline const Aws::String& GetMessageBody() const{ return m_messageBody; }
107 
119  inline bool MessageBodyHasBeenSet() const { return m_messageBodyHasBeenSet; }
120 
132  inline void SetMessageBody(const Aws::String& value) { m_messageBodyHasBeenSet = true; m_messageBody = value; }
133 
145  inline void SetMessageBody(Aws::String&& value) { m_messageBodyHasBeenSet = true; m_messageBody = std::move(value); }
146 
158  inline void SetMessageBody(const char* value) { m_messageBodyHasBeenSet = true; m_messageBody.assign(value); }
159 
171  inline SendMessageRequest& WithMessageBody(const Aws::String& value) { SetMessageBody(value); return *this;}
172 
184  inline SendMessageRequest& WithMessageBody(Aws::String&& value) { SetMessageBody(std::move(value)); return *this;}
185 
197  inline SendMessageRequest& WithMessageBody(const char* value) { SetMessageBody(value); return *this;}
198 
199 
209  inline int GetDelaySeconds() const{ return m_delaySeconds; }
210 
220  inline bool DelaySecondsHasBeenSet() const { return m_delaySecondsHasBeenSet; }
221 
231  inline void SetDelaySeconds(int value) { m_delaySecondsHasBeenSet = true; m_delaySeconds = value; }
232 
242  inline SendMessageRequest& WithDelaySeconds(int value) { SetDelaySeconds(value); return *this;}
243 
244 
252  inline const Aws::Map<Aws::String, MessageAttributeValue>& GetMessageAttributes() const{ return m_messageAttributes; }
253 
261  inline bool MessageAttributesHasBeenSet() const { return m_messageAttributesHasBeenSet; }
262 
270  inline void SetMessageAttributes(const Aws::Map<Aws::String, MessageAttributeValue>& value) { m_messageAttributesHasBeenSet = true; m_messageAttributes = value; }
271 
279  inline void SetMessageAttributes(Aws::Map<Aws::String, MessageAttributeValue>&& value) { m_messageAttributesHasBeenSet = true; m_messageAttributes = std::move(value); }
280 
288  inline SendMessageRequest& WithMessageAttributes(const Aws::Map<Aws::String, MessageAttributeValue>& value) { SetMessageAttributes(value); return *this;}
289 
297  inline SendMessageRequest& WithMessageAttributes(Aws::Map<Aws::String, MessageAttributeValue>&& value) { SetMessageAttributes(std::move(value)); return *this;}
298 
306  inline SendMessageRequest& AddMessageAttributes(const Aws::String& key, const MessageAttributeValue& value) { m_messageAttributesHasBeenSet = true; m_messageAttributes.emplace(key, value); return *this; }
307 
315  inline SendMessageRequest& AddMessageAttributes(Aws::String&& key, const MessageAttributeValue& value) { m_messageAttributesHasBeenSet = true; m_messageAttributes.emplace(std::move(key), value); return *this; }
316 
324  inline SendMessageRequest& AddMessageAttributes(const Aws::String& key, MessageAttributeValue&& value) { m_messageAttributesHasBeenSet = true; m_messageAttributes.emplace(key, std::move(value)); return *this; }
325 
333  inline SendMessageRequest& AddMessageAttributes(Aws::String&& key, MessageAttributeValue&& value) { m_messageAttributesHasBeenSet = true; m_messageAttributes.emplace(std::move(key), std::move(value)); return *this; }
334 
342  inline SendMessageRequest& AddMessageAttributes(const char* key, MessageAttributeValue&& value) { m_messageAttributesHasBeenSet = true; m_messageAttributes.emplace(key, std::move(value)); return *this; }
343 
351  inline SendMessageRequest& AddMessageAttributes(const char* key, const MessageAttributeValue& value) { m_messageAttributesHasBeenSet = true; m_messageAttributes.emplace(key, value); return *this; }
352 
353 
364 
374  inline bool MessageSystemAttributesHasBeenSet() const { return m_messageSystemAttributesHasBeenSet; }
375 
385  inline void SetMessageSystemAttributes(const Aws::Map<MessageSystemAttributeNameForSends, MessageSystemAttributeValue>& value) { m_messageSystemAttributesHasBeenSet = true; m_messageSystemAttributes = value; }
386 
396  inline void SetMessageSystemAttributes(Aws::Map<MessageSystemAttributeNameForSends, MessageSystemAttributeValue>&& value) { m_messageSystemAttributesHasBeenSet = true; m_messageSystemAttributes = std::move(value); }
397 
408 
418  inline SendMessageRequest& WithMessageSystemAttributes(Aws::Map<MessageSystemAttributeNameForSends, MessageSystemAttributeValue>&& value) { SetMessageSystemAttributes(std::move(value)); return *this;}
419 
429  inline SendMessageRequest& AddMessageSystemAttributes(const MessageSystemAttributeNameForSends& key, const MessageSystemAttributeValue& value) { m_messageSystemAttributesHasBeenSet = true; m_messageSystemAttributes.emplace(key, value); return *this; }
430 
440  inline SendMessageRequest& AddMessageSystemAttributes(MessageSystemAttributeNameForSends&& key, const MessageSystemAttributeValue& value) { m_messageSystemAttributesHasBeenSet = true; m_messageSystemAttributes.emplace(std::move(key), value); return *this; }
441 
451  inline SendMessageRequest& AddMessageSystemAttributes(const MessageSystemAttributeNameForSends& key, MessageSystemAttributeValue&& value) { m_messageSystemAttributesHasBeenSet = true; m_messageSystemAttributes.emplace(key, std::move(value)); return *this; }
452 
462  inline SendMessageRequest& AddMessageSystemAttributes(MessageSystemAttributeNameForSends&& key, MessageSystemAttributeValue&& value) { m_messageSystemAttributesHasBeenSet = true; m_messageSystemAttributes.emplace(std::move(key), std::move(value)); return *this; }
463 
464 
508  inline const Aws::String& GetMessageDeduplicationId() const{ return m_messageDeduplicationId; }
509 
553  inline bool MessageDeduplicationIdHasBeenSet() const { return m_messageDeduplicationIdHasBeenSet; }
554 
598  inline void SetMessageDeduplicationId(const Aws::String& value) { m_messageDeduplicationIdHasBeenSet = true; m_messageDeduplicationId = value; }
599 
643  inline void SetMessageDeduplicationId(Aws::String&& value) { m_messageDeduplicationIdHasBeenSet = true; m_messageDeduplicationId = std::move(value); }
644 
688  inline void SetMessageDeduplicationId(const char* value) { m_messageDeduplicationIdHasBeenSet = true; m_messageDeduplicationId.assign(value); }
689 
733  inline SendMessageRequest& WithMessageDeduplicationId(const Aws::String& value) { SetMessageDeduplicationId(value); return *this;}
734 
778  inline SendMessageRequest& WithMessageDeduplicationId(Aws::String&& value) { SetMessageDeduplicationId(std::move(value)); return *this;}
779 
823  inline SendMessageRequest& WithMessageDeduplicationId(const char* value) { SetMessageDeduplicationId(value); return *this;}
824 
825 
850  inline const Aws::String& GetMessageGroupId() const{ return m_messageGroupId; }
851 
876  inline bool MessageGroupIdHasBeenSet() const { return m_messageGroupIdHasBeenSet; }
877 
902  inline void SetMessageGroupId(const Aws::String& value) { m_messageGroupIdHasBeenSet = true; m_messageGroupId = value; }
903 
928  inline void SetMessageGroupId(Aws::String&& value) { m_messageGroupIdHasBeenSet = true; m_messageGroupId = std::move(value); }
929 
954  inline void SetMessageGroupId(const char* value) { m_messageGroupIdHasBeenSet = true; m_messageGroupId.assign(value); }
955 
980  inline SendMessageRequest& WithMessageGroupId(const Aws::String& value) { SetMessageGroupId(value); return *this;}
981 
1006  inline SendMessageRequest& WithMessageGroupId(Aws::String&& value) { SetMessageGroupId(std::move(value)); return *this;}
1007 
1032  inline SendMessageRequest& WithMessageGroupId(const char* value) { SetMessageGroupId(value); return *this;}
1033 
1034  private:
1035 
1036  Aws::String m_queueUrl;
1037  bool m_queueUrlHasBeenSet;
1038 
1039  Aws::String m_messageBody;
1040  bool m_messageBodyHasBeenSet;
1041 
1042  int m_delaySeconds;
1043  bool m_delaySecondsHasBeenSet;
1044 
1046  bool m_messageAttributesHasBeenSet;
1047 
1049  bool m_messageSystemAttributesHasBeenSet;
1050 
1051  Aws::String m_messageDeduplicationId;
1052  bool m_messageDeduplicationIdHasBeenSet;
1053 
1054  Aws::String m_messageGroupId;
1055  bool m_messageGroupIdHasBeenSet;
1056  };
1057 
1058 } // namespace Model
1059 } // namespace SQS
1060 } // namespace Aws
Aws::SQS::Model::SendMessageRequest::SetMessageBody
void SetMessageBody(const Aws::String &value)
Definition: SendMessageRequest.h:132
Aws::SQS::Model::SendMessageRequest::GetMessageSystemAttributes
const Aws::Map< MessageSystemAttributeNameForSends, MessageSystemAttributeValue > & GetMessageSystemAttributes() const
Definition: SendMessageRequest.h:363
Aws::SQS::Model::SendMessageRequest::MessageDeduplicationIdHasBeenSet
bool MessageDeduplicationIdHasBeenSet() const
Definition: SendMessageRequest.h:553
Aws::SQS::Model::SendMessageRequest::SetQueueUrl
void SetQueueUrl(const Aws::String &value)
Definition: SendMessageRequest.h:62
Aws::SQS::Model::SendMessageRequest::WithQueueUrl
SendMessageRequest & WithQueueUrl(Aws::String &&value)
Definition: SendMessageRequest.h:86
Aws::Http::URI
Definition: URI.h:32
Aws::SQS::Model::SendMessageRequest::MessageBodyHasBeenSet
bool MessageBodyHasBeenSet() const
Definition: SendMessageRequest.h:119
Aws::SQS::Model::SendMessageRequest::WithDelaySeconds
SendMessageRequest & WithDelaySeconds(int value)
Definition: SendMessageRequest.h:242
Aws::SQS::Model::SendMessageRequest::WithMessageSystemAttributes
SendMessageRequest & WithMessageSystemAttributes(Aws::Map< MessageSystemAttributeNameForSends, MessageSystemAttributeValue > &&value)
Definition: SendMessageRequest.h:418
Aws::SQS::Model::SendMessageRequest::SetMessageAttributes
void SetMessageAttributes(Aws::Map< Aws::String, MessageAttributeValue > &&value)
Definition: SendMessageRequest.h:279
Aws::SQS::Model::SendMessageRequest::GetMessageBody
const Aws::String & GetMessageBody() const
Definition: SendMessageRequest.h:106
Aws::SQS::Model::SendMessageRequest::WithMessageDeduplicationId
SendMessageRequest & WithMessageDeduplicationId(Aws::String &&value)
Definition: SendMessageRequest.h:778
Aws::SQS::Model::SendMessageRequest::AddMessageSystemAttributes
SendMessageRequest & AddMessageSystemAttributes(MessageSystemAttributeNameForSends &&key, MessageSystemAttributeValue &&value)
Definition: SendMessageRequest.h:462
Aws::SQS::Model::SendMessageRequest::WithMessageDeduplicationId
SendMessageRequest & WithMessageDeduplicationId(const Aws::String &value)
Definition: SendMessageRequest.h:733
Aws::SQS::Model::SendMessageRequest::GetServiceRequestName
virtual const char * GetServiceRequestName() const override
Definition: SendMessageRequest.h:37
Aws::SQS::Model::SendMessageRequest::SetMessageBody
void SetMessageBody(const char *value)
Definition: SendMessageRequest.h:158
MessageSystemAttributeValue.h
Aws::SQS::Model::SendMessageRequest::AddMessageAttributes
SendMessageRequest & AddMessageAttributes(const Aws::String &key, const MessageAttributeValue &value)
Definition: SendMessageRequest.h:306
Aws::SQS::Model::SendMessageRequest::WithQueueUrl
SendMessageRequest & WithQueueUrl(const char *value)
Definition: SendMessageRequest.h:92
Aws::SQS::Model::SendMessageRequest::SetMessageSystemAttributes
void SetMessageSystemAttributes(const Aws::Map< MessageSystemAttributeNameForSends, MessageSystemAttributeValue > &value)
Definition: SendMessageRequest.h:385
Aws::SQS::Model::SendMessageRequest::WithMessageGroupId
SendMessageRequest & WithMessageGroupId(Aws::String &&value)
Definition: SendMessageRequest.h:1006
Aws::SQS::Model::SendMessageRequest::AddMessageSystemAttributes
SendMessageRequest & AddMessageSystemAttributes(const MessageSystemAttributeNameForSends &key, const MessageSystemAttributeValue &value)
Definition: SendMessageRequest.h:429
Aws::SQS::Model::SendMessageRequest::WithMessageBody
SendMessageRequest & WithMessageBody(Aws::String &&value)
Definition: SendMessageRequest.h:184
Aws::SQS::Model::SendMessageRequest::SetMessageBody
void SetMessageBody(Aws::String &&value)
Definition: SendMessageRequest.h:145
Aws::SQS::Model::SendMessageRequest::SendMessageRequest
SendMessageRequest()
Aws::SQS::Model::SendMessageRequest::GetMessageGroupId
const Aws::String & GetMessageGroupId() const
Definition: SendMessageRequest.h:850
Aws::SQS::Model::SendMessageRequest::DelaySecondsHasBeenSet
bool DelaySecondsHasBeenSet() const
Definition: SendMessageRequest.h:220
Aws::SQS::Model::MessageAttributeValue
Definition: MessageAttributeValue.h:41
Aws::SQS::Model::SendMessageRequest::WithMessageGroupId
SendMessageRequest & WithMessageGroupId(const Aws::String &value)
Definition: SendMessageRequest.h:980
Aws::SQS::Model::SendMessageRequest::AddMessageAttributes
SendMessageRequest & AddMessageAttributes(const char *key, const MessageAttributeValue &value)
Definition: SendMessageRequest.h:351
MessageAttributeValue.h
Aws::SQS::Model::SendMessageRequest::SetMessageSystemAttributes
void SetMessageSystemAttributes(Aws::Map< MessageSystemAttributeNameForSends, MessageSystemAttributeValue > &&value)
Definition: SendMessageRequest.h:396
Aws::SQS::Model::SendMessageRequest::WithMessageBody
SendMessageRequest & WithMessageBody(const char *value)
Definition: SendMessageRequest.h:197
MessageSystemAttributeNameForSends.h
Aws::SQS::Model::SendMessageRequest::WithMessageAttributes
SendMessageRequest & WithMessageAttributes(const Aws::Map< Aws::String, MessageAttributeValue > &value)
Definition: SendMessageRequest.h:288
Aws::SQS::Model::SendMessageRequest::SetMessageDeduplicationId
void SetMessageDeduplicationId(const Aws::String &value)
Definition: SendMessageRequest.h:598
Aws::SQS::Model::SendMessageRequest::SetDelaySeconds
void SetDelaySeconds(int value)
Definition: SendMessageRequest.h:231
Aws::SQS::Model::SendMessageRequest::AddMessageAttributes
SendMessageRequest & AddMessageAttributes(const Aws::String &key, MessageAttributeValue &&value)
Definition: SendMessageRequest.h:324
Aws::SQS::Model::SendMessageRequest::GetQueueUrl
const Aws::String & GetQueueUrl() const
Definition: SendMessageRequest.h:50
Aws::SQS::Model::SendMessageRequest::SetMessageGroupId
void SetMessageGroupId(const Aws::String &value)
Definition: SendMessageRequest.h:902
Aws::SQS::Model::SendMessageRequest::AddMessageAttributes
SendMessageRequest & AddMessageAttributes(Aws::String &&key, const MessageAttributeValue &value)
Definition: SendMessageRequest.h:315
Aws::SQS::Model::SendMessageRequest::GetMessageAttributes
const Aws::Map< Aws::String, MessageAttributeValue > & GetMessageAttributes() const
Definition: SendMessageRequest.h:252
Aws::SQS::Model::SendMessageRequest::AddMessageAttributes
SendMessageRequest & AddMessageAttributes(Aws::String &&key, MessageAttributeValue &&value)
Definition: SendMessageRequest.h:333
Aws::SQS::Model::MessageSystemAttributeValue
Definition: MessageSystemAttributeValue.h:38
Aws::Chime::Model::NotificationTarget::NOT_SET
@ NOT_SET
AWSString.h
Aws::SQS::Model::SendMessageRequest::GetDelaySeconds
int GetDelaySeconds() const
Definition: SendMessageRequest.h:209
Aws::SQS::Model::SendMessageRequest::AddMessageSystemAttributes
SendMessageRequest & AddMessageSystemAttributes(MessageSystemAttributeNameForSends &&key, const MessageSystemAttributeValue &value)
Definition: SendMessageRequest.h:440
AWS_SQS_API
#define AWS_SQS_API
Definition: SQS_EXPORTS.h:28
Aws::SQS::Model::SendMessageRequest::WithMessageAttributes
SendMessageRequest & WithMessageAttributes(Aws::Map< Aws::String, MessageAttributeValue > &&value)
Definition: SendMessageRequest.h:297
Aws::SQS::Model::SendMessageRequest::SetMessageDeduplicationId
void SetMessageDeduplicationId(Aws::String &&value)
Definition: SendMessageRequest.h:643
Aws::SQS::Model::SendMessageRequest::WithMessageBody
SendMessageRequest & WithMessageBody(const Aws::String &value)
Definition: SendMessageRequest.h:171
Aws::SQS::Model::SendMessageRequest
Definition: SendMessageRequest.h:29
Aws::SQS::Model::SendMessageRequest::MessageAttributesHasBeenSet
bool MessageAttributesHasBeenSet() const
Definition: SendMessageRequest.h:261
Aws::SQS::Model::SendMessageRequest::MessageSystemAttributesHasBeenSet
bool MessageSystemAttributesHasBeenSet() const
Definition: SendMessageRequest.h:374
SQS_EXPORTS.h
Aws::SQS::Model::SendMessageRequest::DumpBodyToUrl
void DumpBodyToUrl(Aws::Http::URI &uri) const override
Aws::SQS::SQSRequest
Definition: SQSRequest.h:17
Aws
Definition: AccessManagementClient.h:15
Aws::SQS::Model::SendMessageRequest::MessageGroupIdHasBeenSet
bool MessageGroupIdHasBeenSet() const
Definition: SendMessageRequest.h:876
Aws::SQS::Model::SendMessageRequest::SetMessageGroupId
void SetMessageGroupId(Aws::String &&value)
Definition: SendMessageRequest.h:928
Aws::SQS::Model::SendMessageRequest::WithMessageDeduplicationId
SendMessageRequest & WithMessageDeduplicationId(const char *value)
Definition: SendMessageRequest.h:823
Aws::SQS::Model::SendMessageRequest::WithMessageGroupId
SendMessageRequest & WithMessageGroupId(const char *value)
Definition: SendMessageRequest.h:1032
Aws::SQS::Model::SendMessageRequest::SetMessageAttributes
void SetMessageAttributes(const Aws::Map< Aws::String, MessageAttributeValue > &value)
Definition: SendMessageRequest.h:270
Aws::SQS::Model::SendMessageRequest::AddMessageAttributes
SendMessageRequest & AddMessageAttributes(const char *key, MessageAttributeValue &&value)
Definition: SendMessageRequest.h:342
Aws::SQS::Model::SendMessageRequest::WithMessageSystemAttributes
SendMessageRequest & WithMessageSystemAttributes(const Aws::Map< MessageSystemAttributeNameForSends, MessageSystemAttributeValue > &value)
Definition: SendMessageRequest.h:407
Aws::SQS::Model::SendMessageRequest::SetMessageDeduplicationId
void SetMessageDeduplicationId(const char *value)
Definition: SendMessageRequest.h:688
Aws::String
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition: AWSString.h:97
Aws::SQS::Model::SendMessageRequest::QueueUrlHasBeenSet
bool QueueUrlHasBeenSet() const
Definition: SendMessageRequest.h:56
Aws::SQS::Model::SendMessageRequest::SetMessageGroupId
void SetMessageGroupId(const char *value)
Definition: SendMessageRequest.h:954
Aws::SQS::Model::SendMessageRequest::SetQueueUrl
void SetQueueUrl(const char *value)
Definition: SendMessageRequest.h:74
Aws::SQS::Model::SendMessageRequest::SetQueueUrl
void SetQueueUrl(Aws::String &&value)
Definition: SendMessageRequest.h:68
Aws::SQS::Model::SendMessageRequest::GetMessageDeduplicationId
const Aws::String & GetMessageDeduplicationId() const
Definition: SendMessageRequest.h:508
Aws::SQS::Model::MessageSystemAttributeNameForSends
MessageSystemAttributeNameForSends
Definition: MessageSystemAttributeNameForSends.h:17
AWSMap.h
SQSRequest.h
Aws::SQS::Model::SendMessageRequest::SerializePayload
Aws::String SerializePayload() const override
Aws::SQS::Model::SendMessageRequest::AddMessageSystemAttributes
SendMessageRequest & AddMessageSystemAttributes(const MessageSystemAttributeNameForSends &key, MessageSystemAttributeValue &&value)
Definition: SendMessageRequest.h:451
Aws::SQS::Model::SendMessageRequest::WithQueueUrl
SendMessageRequest & WithQueueUrl(const Aws::String &value)
Definition: SendMessageRequest.h:80
Aws::Map
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
Definition: AWSMap.h:19