Rice Pastry API

rice.p2p.past.testing
Class RawPastRegrTest.TestPastContent

java.lang.Object
  extended by rice.p2p.past.testing.RawPastRegrTest.TestPastContent
All Implemented Interfaces:
java.io.Serializable, PastContent, RawPastContent
Direct Known Subclasses:
RawPastRegrTest.NonMutableTestPastContent, RawPastRegrTest.VersionedTestPastContent
Enclosing class:
RawPastRegrTest

protected static class RawPastRegrTest.TestPastContent
extends java.lang.Object
implements RawPastContent

Utility class for past content objects

Version:
$Id: pretty.settings 2305 2005-03-11 20:22:33Z jeffh $
Author:
jeffh
See Also:
Serialized Form

Field Summary
protected  RawPastContent existing
          DESCRIBE THE FIELD
protected  Id id
          DESCRIBE THE FIELD
static short TYPE
          DESCRIBE THE FIELD
 
Constructor Summary
RawPastRegrTest.TestPastContent(Id id)
          Constructor for TestPastContent.
RawPastRegrTest.TestPastContent(InputBuffer buf, Endpoint endpoint, PastContentDeserializer pcd)
          Constructor for TestPastContent.
 
Method Summary
 PastContent checkInsert(Id id, PastContent existingContent)
          DESCRIBE THE METHOD
 boolean equals(java.lang.Object o)
          Compares this to the parameter.
 PastContentHandle getHandle(Past past)
          Gets the Handle attribute of the TestPastContent object
 Id getId()
          Gets the Id attribute of the TestPastContent object
 short getType()
          Gets the Type attribute of the TestPastContent object
 boolean isMutable()
          Gets the Mutable attribute of the TestPastContent object
 void serialize(OutputBuffer buf)
          DESCRIBE THE METHOD
 java.lang.String toString()
          Converts to a String representation of the object.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

id

protected Id id
DESCRIBE THE FIELD


existing

protected RawPastContent existing
DESCRIBE THE FIELD


TYPE

public static final short TYPE
DESCRIBE THE FIELD

See Also:
Constant Field Values
Constructor Detail

RawPastRegrTest.TestPastContent

public RawPastRegrTest.TestPastContent(Id id)
Constructor for TestPastContent.

Parameters:
id - DESCRIBE THE PARAMETER

RawPastRegrTest.TestPastContent

public RawPastRegrTest.TestPastContent(InputBuffer buf,
                                       Endpoint endpoint,
                                       PastContentDeserializer pcd)
                                throws java.io.IOException
Constructor for TestPastContent.

Parameters:
buf - DESCRIBE THE PARAMETER
endpoint - DESCRIBE THE PARAMETER
pcd - DESCRIBE THE PARAMETER
Throws:
java.io.IOException - DESCRIBE THE EXCEPTION
Method Detail

getHandle

public PastContentHandle getHandle(Past past)
Gets the Handle attribute of the TestPastContent object

Specified by:
getHandle in interface PastContent
Parameters:
past - DESCRIBE THE PARAMETER
Returns:
The Handle value

getId

public Id getId()
Gets the Id attribute of the TestPastContent object

Specified by:
getId in interface PastContent
Returns:
The Id value

isMutable

public boolean isMutable()
Gets the Mutable attribute of the TestPastContent object

Specified by:
isMutable in interface PastContent
Returns:
The Mutable value

getType

public short getType()
Gets the Type attribute of the TestPastContent object

Specified by:
getType in interface RawPastContent
Returns:
The Type value

checkInsert

public PastContent checkInsert(Id id,
                               PastContent existingContent)
                        throws PastException
DESCRIBE THE METHOD

Specified by:
checkInsert in interface PastContent
Parameters:
id - DESCRIBE THE PARAMETER
existingContent - DESCRIBE THE PARAMETER
Returns:
DESCRIBE THE RETURN VALUE
Throws:
PastException - DESCRIBE THE EXCEPTION

equals

public boolean equals(java.lang.Object o)
Compares this to the parameter.

Overrides:
equals in class java.lang.Object
Parameters:
o - the reference object with which to compare.
Returns:
true if this object is the same as the obj argument; false otherwise.

toString

public java.lang.String toString()
Converts to a String representation of the object.

Overrides:
toString in class java.lang.Object
Returns:
A string representation of the object.

serialize

public void serialize(OutputBuffer buf)
               throws java.io.IOException
DESCRIBE THE METHOD

Specified by:
serialize in interface RawPastContent
Parameters:
buf - DESCRIBE THE PARAMETER
Throws:
java.io.IOException - DESCRIBE THE EXCEPTION

Rice Pastry API

Copyright © 2001-2005 - Rice Pastry.