public class SendMessageBatchRequestEntry
extends java.lang.Object
implements java.io.Serializable, java.lang.Cloneable
Contains the details of a single Amazon SQS message along with a
Id
.
Modifier and Type | Field and Description |
---|---|
private java.lang.Integer |
delaySeconds
The number of seconds for which the message has to be delayed.
|
private java.lang.String |
id
An identifier for the message in this batch.
|
private SdkInternalMap<java.lang.String,MessageAttributeValue> |
messageAttributes
Each message attribute consists of a Name, Type, and Value.
|
private java.lang.String |
messageBody
Body of the message.
|
Constructor and Description |
---|
SendMessageBatchRequestEntry()
Default constructor for SendMessageBatchRequestEntry object.
|
SendMessageBatchRequestEntry(java.lang.String id,
java.lang.String messageBody)
Constructs a new SendMessageBatchRequestEntry object.
|
Modifier and Type | Method and Description |
---|---|
SendMessageBatchRequestEntry |
addMessageAttributesEntry(java.lang.String key,
MessageAttributeValue value) |
SendMessageBatchRequestEntry |
clearMessageAttributesEntries()
Removes all the entries added into MessageAttributes.
|
SendMessageBatchRequestEntry |
clone() |
boolean |
equals(java.lang.Object obj) |
java.lang.Integer |
getDelaySeconds()
The number of seconds for which the message has to be delayed.
|
java.lang.String |
getId()
An identifier for the message in this batch.
|
java.util.Map<java.lang.String,MessageAttributeValue> |
getMessageAttributes()
Each message attribute consists of a Name, Type, and Value.
|
java.lang.String |
getMessageBody()
Body of the message.
|
int |
hashCode() |
void |
setDelaySeconds(java.lang.Integer delaySeconds)
The number of seconds for which the message has to be delayed.
|
void |
setId(java.lang.String id)
An identifier for the message in this batch.
|
void |
setMessageAttributes(java.util.Map<java.lang.String,MessageAttributeValue> messageAttributes)
Each message attribute consists of a Name, Type, and Value.
|
void |
setMessageBody(java.lang.String messageBody)
Body of the message.
|
java.lang.String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
SendMessageBatchRequestEntry |
withDelaySeconds(java.lang.Integer delaySeconds)
The number of seconds for which the message has to be delayed.
|
SendMessageBatchRequestEntry |
withId(java.lang.String id)
An identifier for the message in this batch.
|
SendMessageBatchRequestEntry |
withMessageAttributes(java.util.Map<java.lang.String,MessageAttributeValue> messageAttributes)
Each message attribute consists of a Name, Type, and Value.
|
SendMessageBatchRequestEntry |
withMessageBody(java.lang.String messageBody)
Body of the message.
|
private java.lang.String id
An identifier for the message in this batch. This is used to communicate
the result. Note that the Id
s of a batch request need to be
unique within the request.
private java.lang.String messageBody
Body of the message.
private java.lang.Integer delaySeconds
The number of seconds for which the message has to be delayed.
private SdkInternalMap<java.lang.String,MessageAttributeValue> messageAttributes
Each message attribute consists of a Name, Type, and Value. For more information, see Message Attribute Items.
public SendMessageBatchRequestEntry()
public SendMessageBatchRequestEntry(java.lang.String id, java.lang.String messageBody)
id
- An identifier for the message in this batch. This is used to
communicate the result. Note that the Id
s of a batch
request need to be unique within the request.messageBody
- Body of the message.public void setId(java.lang.String id)
An identifier for the message in this batch. This is used to communicate
the result. Note that the Id
s of a batch request need to be
unique within the request.
id
- An identifier for the message in this batch. This is used to
communicate the result. Note that the Id
s of a batch
request need to be unique within the request.public java.lang.String getId()
An identifier for the message in this batch. This is used to communicate
the result. Note that the Id
s of a batch request need to be
unique within the request.
Id
s of a batch
request need to be unique within the request.public SendMessageBatchRequestEntry withId(java.lang.String id)
An identifier for the message in this batch. This is used to communicate
the result. Note that the Id
s of a batch request need to be
unique within the request.
id
- An identifier for the message in this batch. This is used to
communicate the result. Note that the Id
s of a batch
request need to be unique within the request.public void setMessageBody(java.lang.String messageBody)
Body of the message.
messageBody
- Body of the message.public java.lang.String getMessageBody()
Body of the message.
public SendMessageBatchRequestEntry withMessageBody(java.lang.String messageBody)
Body of the message.
messageBody
- Body of the message.public void setDelaySeconds(java.lang.Integer delaySeconds)
The number of seconds for which the message has to be delayed.
delaySeconds
- The number of seconds for which the message has to be delayed.public java.lang.Integer getDelaySeconds()
The number of seconds for which the message has to be delayed.
public SendMessageBatchRequestEntry withDelaySeconds(java.lang.Integer delaySeconds)
The number of seconds for which the message has to be delayed.
delaySeconds
- The number of seconds for which the message has to be delayed.public java.util.Map<java.lang.String,MessageAttributeValue> getMessageAttributes()
Each message attribute consists of a Name, Type, and Value. For more information, see Message Attribute Items.
public void setMessageAttributes(java.util.Map<java.lang.String,MessageAttributeValue> messageAttributes)
Each message attribute consists of a Name, Type, and Value. For more information, see Message Attribute Items.
messageAttributes
- Each message attribute consists of a Name, Type, and Value. For
more information, see Message Attribute Items.public SendMessageBatchRequestEntry withMessageAttributes(java.util.Map<java.lang.String,MessageAttributeValue> messageAttributes)
Each message attribute consists of a Name, Type, and Value. For more information, see Message Attribute Items.
messageAttributes
- Each message attribute consists of a Name, Type, and Value. For
more information, see Message Attribute Items.public SendMessageBatchRequestEntry addMessageAttributesEntry(java.lang.String key, MessageAttributeValue value)
public SendMessageBatchRequestEntry clearMessageAttributesEntries()
public java.lang.String toString()
toString
in class java.lang.Object
Object.toString()
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public SendMessageBatchRequestEntry clone()
clone
in class java.lang.Object