Did this page help you?

   Yes   No   Tell us about it...

com.amazonaws.services.sqs.model
Class Message

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

public class Message
extends Object
implements Serializable

Message

See Also:
Serialized Form

Constructor Summary
Message()
          Default constructor for a new Message object.
 
Method Summary
 Message addAttributesEntry(String key, String value)
          Sets the value of the Attributes property for this object.
 Message clearAttributesEntries()
          Removes all the entries added into Attributes.
 boolean equals(Object obj)
           
 Map<String,String> getAttributes()
          Returns the value of the Attributes property for this object.
 String getBody()
          Returns the value of the Body property for this object.
 String getMD5OfBody()
          Returns the value of the MD5OfBody property for this object.
 String getMessageId()
          Returns the value of the MessageId property for this object.
 String getReceiptHandle()
          Returns the value of the ReceiptHandle property for this object.
 int hashCode()
           
 void setAttributes(Map<String,String> attributes)
          Sets the value of the Attributes property for this object.
 void setBody(String body)
          Sets the value of the Body property for this object.
 void setMD5OfBody(String mD5OfBody)
          Sets the value of the MD5OfBody property for this object.
 void setMessageId(String messageId)
          Sets the value of the MessageId property for this object.
 void setReceiptHandle(String receiptHandle)
          Sets the value of the ReceiptHandle property for this object.
 String toString()
          Returns a string representation of this object; useful for testing and debugging.
 Message withAttributes(Map<String,String> attributes)
          Sets the value of the Attributes property for this object.
 Message withBody(String body)
          Sets the value of the Body property for this object.
 Message withMD5OfBody(String mD5OfBody)
          Sets the value of the MD5OfBody property for this object.
 Message withMessageId(String messageId)
          Sets the value of the MessageId property for this object.
 Message withReceiptHandle(String receiptHandle)
          Sets the value of the ReceiptHandle property for this object.
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Message

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

Method Detail

getMessageId

public String getMessageId()
Returns the value of the MessageId property for this object.

Returns:
The value of the MessageId property for this object.

setMessageId

public void setMessageId(String messageId)
Sets the value of the MessageId property for this object.

Parameters:
messageId - The new value for the MessageId property for this object.

withMessageId

public Message withMessageId(String messageId)
Sets the value of the MessageId property for this object.

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

Parameters:
messageId - The new value for the MessageId property for this object.

getReceiptHandle

public String getReceiptHandle()
Returns the value of the ReceiptHandle property for this object.

Returns:
The value of the ReceiptHandle property for this object.

setReceiptHandle

public void setReceiptHandle(String receiptHandle)
Sets the value of the ReceiptHandle property for this object.

Parameters:
receiptHandle - The new value for the ReceiptHandle property for this object.

withReceiptHandle

public Message withReceiptHandle(String receiptHandle)
Sets the value of the ReceiptHandle property for this object.

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

Parameters:
receiptHandle - The new value for the ReceiptHandle property for this object.

getMD5OfBody

public String getMD5OfBody()
Returns the value of the MD5OfBody property for this object.

Returns:
The value of the MD5OfBody property for this object.

setMD5OfBody

public void setMD5OfBody(String mD5OfBody)
Sets the value of the MD5OfBody property for this object.

Parameters:
mD5OfBody - The new value for the MD5OfBody property for this object.

withMD5OfBody

public Message withMD5OfBody(String mD5OfBody)
Sets the value of the MD5OfBody property for this object.

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

Parameters:
mD5OfBody - The new value for the MD5OfBody property for this object.

getBody

public String getBody()
Returns the value of the Body property for this object.

Returns:
The value of the Body property for this object.

setBody

public void setBody(String body)
Sets the value of the Body property for this object.

Parameters:
body - The new value for the Body property for this object.

withBody

public Message withBody(String body)
Sets the value of the Body property for this object.

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

Parameters:
body - The new value for the Body property for this object.

getAttributes

public Map<String,String> getAttributes()
Returns the value of the Attributes property for this object.

Returns:
The value of the Attributes property for this object.

setAttributes

public void setAttributes(Map<String,String> attributes)
Sets the value of the Attributes property for this object.

Parameters:
attributes - The new value for the Attributes property for this object.

withAttributes

public Message withAttributes(Map<String,String> attributes)
Sets the value of the Attributes property for this object.

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

Parameters:
attributes - The new value for the Attributes property for this object.

addAttributesEntry

public Message addAttributesEntry(String key,
                                  String value)
Sets the value of the Attributes property for this object.

The method adds a new key-value pair into Attributes 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 Attributes.
value - The corresponding value of the entry to be added into Attributes.

clearAttributesEntries

public Message clearAttributesEntries()
Removes all the entries added into Attributes.

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:
Object.toString()

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

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


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