public class Message extends java.lang.Object implements objects.ConfigurableObject, TimestampedObject, com.gemstone.gemfire.cache.util.ObjectSizer, com.gemstone.gemfire.DataSerializable
| Constructor and Description |
|---|
Message() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object o)
Two
Messages are considered to be equal if they have
the same content (index) and timestamp. |
void |
fromData(java.io.DataInput in) |
int |
getIndex() |
long |
getTimestamp()
Returns the object creation timestamp encoded in the object.
|
void |
init(int index) |
void |
resetTimestamp()
Resets the timestamp encoded in the object to the current time.
|
int |
sizeof(java.lang.Object o) |
void |
toData(java.io.DataOutput out) |
java.lang.String |
toString() |
void |
validate(int index) |
public void init(int index)
init in interface objects.ConfigurableObjectpublic int getIndex()
getIndex in interface objects.ConfigurableObjectpublic void validate(int index)
validate in interface objects.ConfigurableObjectpublic long getTimestamp()
TimestampedObjectgetTimestamp in interface TimestampedObjectpublic void resetTimestamp()
TimestampedObjectresetTimestamp in interface TimestampedObjectpublic java.lang.String toString()
toString in class java.lang.Objectpublic boolean equals(java.lang.Object o)
Messages are considered to be equal if they have
the same content (index) and timestamp.
This provides stronger validation than the validate(int)
method that only considers the index.equals in class java.lang.Objectpublic int sizeof(java.lang.Object o)
sizeof in interface com.gemstone.gemfire.cache.util.ObjectSizerpublic void toData(java.io.DataOutput out)
throws java.io.IOException
toData in interface com.gemstone.gemfire.DataSerializablejava.io.IOExceptionpublic void fromData(java.io.DataInput in)
throws java.io.IOException,
java.lang.ClassNotFoundException
fromData in interface com.gemstone.gemfire.DataSerializablejava.io.IOExceptionjava.lang.ClassNotFoundExceptionCopyright © 2010-2015 Pivotal Software, Inc. All rights reserved.