@Generated(value="com.amazonaws:aws-java-sdk-code-generator") public class Message extends Object implements Serializable, Cloneable
An Amazon SQS message.
Constructor and Description |
---|
Message() |
Modifier and Type | Method and Description |
---|---|
Message |
addAttributesEntry(String key,
String value) |
Message |
addMessageAttributesEntry(String key,
MessageAttributeValue value) |
Message |
clearAttributesEntries()
Removes all the entries added into Attributes.
|
Message |
clearMessageAttributesEntries()
Removes all the entries added into MessageAttributes.
|
Message |
clone() |
boolean |
equals(Object obj) |
Map<String,String> |
getAttributes()
A map of the attributes requested in
ReceiveMessage to their respective values. |
String |
getBody()
The message's contents (not URL-encoded).
|
String |
getMD5OfBody()
An MD5 digest of the non-URL-encoded message body string.
|
String |
getMD5OfMessageAttributes()
An MD5 digest of the non-URL-encoded message attribute string.
|
Map<String,MessageAttributeValue> |
getMessageAttributes()
Each message attribute consists of a
Name , Type , and Value . |
String |
getMessageId()
A unique identifier for the message.
|
String |
getReceiptHandle()
An identifier associated with the act of receiving the message.
|
int |
hashCode() |
void |
setAttributes(Map<String,String> attributes)
A map of the attributes requested in
ReceiveMessage to their respective values. |
void |
setBody(String body)
The message's contents (not URL-encoded).
|
void |
setMD5OfBody(String mD5OfBody)
An MD5 digest of the non-URL-encoded message body string.
|
void |
setMD5OfMessageAttributes(String mD5OfMessageAttributes)
An MD5 digest of the non-URL-encoded message attribute string.
|
void |
setMessageAttributes(Map<String,MessageAttributeValue> messageAttributes)
Each message attribute consists of a
Name , Type , and Value . |
void |
setMessageId(String messageId)
A unique identifier for the message.
|
void |
setReceiptHandle(String receiptHandle)
An identifier associated with the act of receiving the message.
|
String |
toString()
Returns a string representation of this object; useful for testing and debugging.
|
Message |
withAttributes(Map<String,String> attributes)
A map of the attributes requested in
ReceiveMessage to their respective values. |
Message |
withBody(String body)
The message's contents (not URL-encoded).
|
Message |
withMD5OfBody(String mD5OfBody)
An MD5 digest of the non-URL-encoded message body string.
|
Message |
withMD5OfMessageAttributes(String mD5OfMessageAttributes)
An MD5 digest of the non-URL-encoded message attribute string.
|
Message |
withMessageAttributes(Map<String,MessageAttributeValue> messageAttributes)
Each message attribute consists of a
Name , Type , and Value . |
Message |
withMessageId(String messageId)
A unique identifier for the message.
|
Message |
withReceiptHandle(String receiptHandle)
An identifier associated with the act of receiving the message.
|
public void setMessageId(String messageId)
A unique identifier for the message. A MessageId
is considered unique across all AWS accounts for an
extended period of time.
messageId
- A unique identifier for the message. A MessageId
is considered unique across all AWS accounts
for an extended period of time.public String getMessageId()
A unique identifier for the message. A MessageId
is considered unique across all AWS accounts for an
extended period of time.
MessageId
is considered unique across all AWS accounts
for an extended period of time.public Message withMessageId(String messageId)
A unique identifier for the message. A MessageId
is considered unique across all AWS accounts for an
extended period of time.
messageId
- A unique identifier for the message. A MessageId
is considered unique across all AWS accounts
for an extended period of time.public void setReceiptHandle(String receiptHandle)
An identifier associated with the act of receiving the message. A new receipt handle is returned every time you receive a message. When deleting a message, you provide the last received receipt handle to delete the message.
receiptHandle
- An identifier associated with the act of receiving the message. A new receipt handle is returned every
time you receive a message. When deleting a message, you provide the last received receipt handle to
delete the message.public String getReceiptHandle()
An identifier associated with the act of receiving the message. A new receipt handle is returned every time you receive a message. When deleting a message, you provide the last received receipt handle to delete the message.
public Message withReceiptHandle(String receiptHandle)
An identifier associated with the act of receiving the message. A new receipt handle is returned every time you receive a message. When deleting a message, you provide the last received receipt handle to delete the message.
receiptHandle
- An identifier associated with the act of receiving the message. A new receipt handle is returned every
time you receive a message. When deleting a message, you provide the last received receipt handle to
delete the message.public void setMD5OfBody(String mD5OfBody)
An MD5 digest of the non-URL-encoded message body string.
mD5OfBody
- An MD5 digest of the non-URL-encoded message body string.public String getMD5OfBody()
An MD5 digest of the non-URL-encoded message body string.
public Message withMD5OfBody(String mD5OfBody)
An MD5 digest of the non-URL-encoded message body string.
mD5OfBody
- An MD5 digest of the non-URL-encoded message body string.public void setBody(String body)
The message's contents (not URL-encoded).
body
- The message's contents (not URL-encoded).public String getBody()
The message's contents (not URL-encoded).
public Message withBody(String body)
The message's contents (not URL-encoded).
body
- The message's contents (not URL-encoded).public Map<String,String> getAttributes()
A map of the attributes requested in ReceiveMessage
to their respective values. Supported
attributes:
ApproximateReceiveCount
ApproximateFirstReceiveTimestamp
MessageDeduplicationId
MessageGroupId
SenderId
SentTimestamp
SequenceNumber
ApproximateFirstReceiveTimestamp
and SentTimestamp
are each returned as an integer
representing the epoch time in milliseconds.
ReceiveMessage
to their respective values.
Supported attributes:
ApproximateReceiveCount
ApproximateFirstReceiveTimestamp
MessageDeduplicationId
MessageGroupId
SenderId
SentTimestamp
SequenceNumber
ApproximateFirstReceiveTimestamp
and SentTimestamp
are each returned as an
integer representing the epoch time in milliseconds.
public void setAttributes(Map<String,String> attributes)
A map of the attributes requested in ReceiveMessage
to their respective values. Supported
attributes:
ApproximateReceiveCount
ApproximateFirstReceiveTimestamp
MessageDeduplicationId
MessageGroupId
SenderId
SentTimestamp
SequenceNumber
ApproximateFirstReceiveTimestamp
and SentTimestamp
are each returned as an integer
representing the epoch time in milliseconds.
attributes
- A map of the attributes requested in ReceiveMessage
to their respective values.
Supported attributes:
ApproximateReceiveCount
ApproximateFirstReceiveTimestamp
MessageDeduplicationId
MessageGroupId
SenderId
SentTimestamp
SequenceNumber
ApproximateFirstReceiveTimestamp
and SentTimestamp
are each returned as an
integer representing the epoch time in milliseconds.
public Message withAttributes(Map<String,String> attributes)
A map of the attributes requested in ReceiveMessage
to their respective values. Supported
attributes:
ApproximateReceiveCount
ApproximateFirstReceiveTimestamp
MessageDeduplicationId
MessageGroupId
SenderId
SentTimestamp
SequenceNumber
ApproximateFirstReceiveTimestamp
and SentTimestamp
are each returned as an integer
representing the epoch time in milliseconds.
attributes
- A map of the attributes requested in ReceiveMessage
to their respective values.
Supported attributes:
ApproximateReceiveCount
ApproximateFirstReceiveTimestamp
MessageDeduplicationId
MessageGroupId
SenderId
SentTimestamp
SequenceNumber
ApproximateFirstReceiveTimestamp
and SentTimestamp
are each returned as an
integer representing the epoch time in milliseconds.
public Message clearAttributesEntries()
public void setMD5OfMessageAttributes(String mD5OfMessageAttributes)
An MD5 digest of the non-URL-encoded message attribute string. You can use this attribute to verify that Amazon SQS received the message correctly. Amazon SQS URL-decodes the message before creating the MD5 digest. For information about MD5, see RFC1321.
mD5OfMessageAttributes
- An MD5 digest of the non-URL-encoded message attribute string. You can use this attribute to verify that
Amazon SQS received the message correctly. Amazon SQS URL-decodes the message before creating the MD5
digest. For information about MD5, see RFC1321.public String getMD5OfMessageAttributes()
An MD5 digest of the non-URL-encoded message attribute string. You can use this attribute to verify that Amazon SQS received the message correctly. Amazon SQS URL-decodes the message before creating the MD5 digest. For information about MD5, see RFC1321.
public Message withMD5OfMessageAttributes(String mD5OfMessageAttributes)
An MD5 digest of the non-URL-encoded message attribute string. You can use this attribute to verify that Amazon SQS received the message correctly. Amazon SQS URL-decodes the message before creating the MD5 digest. For information about MD5, see RFC1321.
mD5OfMessageAttributes
- An MD5 digest of the non-URL-encoded message attribute string. You can use this attribute to verify that
Amazon SQS received the message correctly. Amazon SQS URL-decodes the message before creating the MD5
digest. For information about MD5, see RFC1321.public Map<String,MessageAttributeValue> getMessageAttributes()
Each message attribute consists of a Name
, Type
, and Value
. For more
information, see Amazon SQS Message Attributes in the Amazon Simple Queue Service Developer Guide.
Name
, Type
, and Value
. For
more information, see Amazon SQS Message Attributes in the Amazon Simple Queue Service Developer Guide.public void setMessageAttributes(Map<String,MessageAttributeValue> messageAttributes)
Each message attribute consists of a Name
, Type
, and Value
. For more
information, see Amazon SQS Message Attributes in the Amazon Simple Queue Service Developer Guide.
messageAttributes
- Each message attribute consists of a Name
, Type
, and Value
. For
more information, see Amazon SQS Message Attributes in the Amazon Simple Queue Service Developer Guide.public Message withMessageAttributes(Map<String,MessageAttributeValue> messageAttributes)
Each message attribute consists of a Name
, Type
, and Value
. For more
information, see Amazon SQS Message Attributes in the Amazon Simple Queue Service Developer Guide.
messageAttributes
- Each message attribute consists of a Name
, Type
, and Value
. For
more information, see Amazon SQS Message Attributes in the Amazon Simple Queue Service Developer Guide.public Message addMessageAttributesEntry(String key, MessageAttributeValue value)
public Message clearMessageAttributesEntries()
public String toString()
toString
in class Object
Object.toString()
Copyright © 2018. All rights reserved.