com.amazonaws.services.sqs.model
Class SendMessageBatchRequestEntry

java.lang.Object
  extended by com.amazonaws.services.sqs.model.SendMessageBatchRequestEntry
All Implemented Interfaces:
java.io.Serializable

public class SendMessageBatchRequestEntry
extends java.lang.Object
implements java.io.Serializable

Contains the details of a single Amazon SQS message along with a Id .

See Also:
Serialized Form

Constructor Summary
SendMessageBatchRequestEntry()
          Default constructor for a new SendMessageBatchRequestEntry object.
SendMessageBatchRequestEntry(java.lang.String id, java.lang.String messageBody)
          Constructs a new SendMessageBatchRequestEntry object.
 
Method Summary
 SendMessageBatchRequestEntry addMessageAttributesEntry(java.lang.String key, MessageAttributeValue value)
          Each message attribute consists of a Name, Type, and Value.
 SendMessageBatchRequestEntry clearMessageAttributesEntries()
          Removes all the entries added into MessageAttributes.
 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.
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SendMessageBatchRequestEntry

public SendMessageBatchRequestEntry()
Default constructor for a new SendMessageBatchRequestEntry object. Callers should use the setter or fluent setter (with...) methods to initialize this object after creating it.


SendMessageBatchRequestEntry

public SendMessageBatchRequestEntry(java.lang.String id,
                                    java.lang.String messageBody)
Constructs a new SendMessageBatchRequestEntry object. Callers should use the setter or fluent setter (with...) methods to initialize any additional object members.

Parameters:
id - An identifier for the message in this batch. This is used to communicate the result. Note that the Ids of a batch request need to be unique within the request.
messageBody - Body of the message.
Method Detail

getId

public java.lang.String getId()
An identifier for the message in this batch. This is used to communicate the result. Note that the Ids of a batch request need to be unique within the request.

Returns:
An identifier for the message in this batch. This is used to communicate the result. Note that the Ids of a batch request need to be unique within the request.

setId

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 Ids of a batch request need to be unique within the request.

Parameters:
id - An identifier for the message in this batch. This is used to communicate the result. Note that the Ids of a batch request need to be unique within the request.

withId

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 Ids of a batch request need to be unique within the request.

Returns a reference to this object so that method calls can be chained together.

Parameters:
id - An identifier for the message in this batch. This is used to communicate the result. Note that the Ids of a batch request need to be unique within the request.
Returns:
A reference to this updated object so that method calls can be chained together.

getMessageBody

public java.lang.String getMessageBody()
Body of the message.

Returns:
Body of the message.

setMessageBody

public void setMessageBody(java.lang.String messageBody)
Body of the message.

Parameters:
messageBody - Body of the message.

withMessageBody

public SendMessageBatchRequestEntry withMessageBody(java.lang.String messageBody)
Body of the message.

Returns a reference to this object so that method calls can be chained together.

Parameters:
messageBody - Body of the message.
Returns:
A reference to this updated object so that method calls can be chained together.

getDelaySeconds

public java.lang.Integer getDelaySeconds()
The number of seconds for which the message has to be delayed.

Returns:
The number of seconds for which the message has to be delayed.

setDelaySeconds

public void setDelaySeconds(java.lang.Integer delaySeconds)
The number of seconds for which the message has to be delayed.

Parameters:
delaySeconds - The number of seconds for which the message has to be delayed.

withDelaySeconds

public SendMessageBatchRequestEntry withDelaySeconds(java.lang.Integer delaySeconds)
The number of seconds for which the message has to be delayed.

Returns a reference to this object so that method calls can be chained together.

Parameters:
delaySeconds - The number of seconds for which the message has to be delayed.
Returns:
A reference to this updated object so that method calls can be chained together.

getMessageAttributes

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.

Returns:
Each message attribute consists of a Name, Type, and Value. For more information, see Message Attribute Items.

setMessageAttributes

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.

Parameters:
messageAttributes - Each message attribute consists of a Name, Type, and Value. For more information, see Message Attribute Items.

withMessageAttributes

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.

Returns a reference to this object so that method calls can be chained together.

Parameters:
messageAttributes - Each message attribute consists of a Name, Type, and Value. For more information, see Message Attribute Items.
Returns:
A reference to this updated object so that method calls can be chained together.

addMessageAttributesEntry

public SendMessageBatchRequestEntry addMessageAttributesEntry(java.lang.String key,
                                                              MessageAttributeValue value)
Each message attribute consists of a Name, Type, and Value. For more information, see Message Attribute Items.

The method adds a new key-value pair into MessageAttributes parameter, and returns a reference to this object so that method calls can be chained together.

Parameters:
key - The key of the entry to be added into MessageAttributes.
value - The corresponding value of the entry to be added into MessageAttributes.

clearMessageAttributesEntries

public SendMessageBatchRequestEntry clearMessageAttributesEntries()
Removes all the entries added into MessageAttributes.

Returns a reference to this object so that method calls can be chained together.


toString

public java.lang.String toString()
Returns a string representation of this object; useful for testing and debugging.

Overrides:
toString in class java.lang.Object
Returns:
A string representation of this object.
See Also:
Object.toString()

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object obj)
Overrides:
equals in class java.lang.Object


Copyright © 2010 Amazon Web Services, Inc. All Rights Reserved.