Class SendMessageBatchRequestEntry

java.lang.Object
com.amazonaws.services.sqs.model.SendMessageBatchRequestEntry
All Implemented Interfaces:
Serializable, Cloneable

public class SendMessageBatchRequestEntry extends Object implements Serializable, Cloneable

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

See Also:
  • Constructor Details

    • SendMessageBatchRequestEntry

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

      public SendMessageBatchRequestEntry(String id, 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 Details

    • setId

      public void setId(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.
    • getId

      public 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.
    • withId

      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.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • setMessageBody

      public void setMessageBody(String messageBody)

      Body of the message.

      Parameters:
      messageBody - Body of the message.
    • getMessageBody

      public String getMessageBody()

      Body of the message.

      Returns:
      Body of the message.
    • withMessageBody

      public SendMessageBatchRequestEntry withMessageBody(String messageBody)

      Body of the message.

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

      public void setDelaySeconds(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.
    • getDelaySeconds

      public 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.
    • withDelaySeconds

      public SendMessageBatchRequestEntry withDelaySeconds(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.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • getMessageAttributes

      public Map<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(Map<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(Map<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.
      Returns:
      Returns a reference to this object so that method calls can be chained together.
    • addMessageAttributesEntry

      public SendMessageBatchRequestEntry addMessageAttributesEntry(String key, MessageAttributeValue value)
    • clearMessageAttributesEntries

      public SendMessageBatchRequestEntry clearMessageAttributesEntries()
      Removes all the entries added into MessageAttributes. <p> Returns a reference to this object so that method calls can be chained together.
    • toString

      public String toString()
      Returns a string representation of this object; useful for testing and debugging.
      Overrides:
      toString in class Object
      Returns:
      A string representation of this object.
      See Also:
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • clone

      Overrides:
      clone in class Object