uk.ac.cam.acr31.android.geomessaging.servertools
Class Message

java.lang.Object
  extended by uk.ac.cam.acr31.android.geomessaging.servertools.Message

public class Message
extends java.lang.Object

A geotagged message returned from the server. This class wraps the two aspects of a message: the message text itself and the URL from which to request the associated image.

Author:
acr31

Field Summary
private  java.lang.String message
          The message text itself
private  java.lang.String pictureUri
          The URL of the image for this message
 
Constructor Summary
Message()
           
 
Method Summary
 boolean equals(java.lang.Object obj)
          Two messages are equal if their picture URL and message text are equal
 java.lang.String getMessage()
          Return the message text
 java.lang.String getPictureUri()
          Returns the absolute URL for the image associated with this message
 int hashCode()
          Two messages have the same hashcode if their picture URL and message text are the same
 void setMessage(java.lang.String message)
          Store the text of this message
 void setPictureUri(java.lang.String pictureUri)
          Store the absolute image URL for this message
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

pictureUri

private java.lang.String pictureUri
The URL of the image for this message


message

private java.lang.String message
The message text itself

Constructor Detail

Message

public Message()
Method Detail

getPictureUri

public java.lang.String getPictureUri()
Returns the absolute URL for the image associated with this message


setPictureUri

public void setPictureUri(java.lang.String pictureUri)
Store the absolute image URL for this message


getMessage

public java.lang.String getMessage()
Return the message text


setMessage

public void setMessage(java.lang.String message)
Store the text of this message


hashCode

public int hashCode()
Two messages have the same hashcode if their picture URL and message text are the same

Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object obj)
Two messages are equal if their picture URL and message text are equal

Overrides:
equals in class java.lang.Object