neustore.base
Interface Data

All Known Implementing Classes:
StringData

public interface Data

Interface for the data part of a record.

Author:
Tian Xia <tianxia@ccs.neu.edu>
Donghui Zhang <donghui@ccs.neu.edu>
See Also:
Key

Method Summary
 java.lang.Object clone()
          Creates a new copy of the object.
 int maxSize()
          Returns the maximum number of bytes this type of object may occupy.
 void read(java.io.DataInputStream in)
          Reads the object from an input stream.
 int size()
           
 void write(java.io.DataOutputStream out)
          Writes the object to an output stream.
 

Method Detail

clone

java.lang.Object clone()
Creates a new copy of the object.

Returns:
the new copy

size

int size()

maxSize

int maxSize()
Returns the maximum number of bytes this type of object may occupy. It is used to support variable-length data.

Returns:
maximum number of bytes

read

void read(java.io.DataInputStream in)
          throws java.io.IOException
Reads the object from an input stream.

Parameters:
in - input stream
Throws:
java.io.IOException

write

void write(java.io.DataOutputStream out)
           throws java.io.IOException
Writes the object to an output stream.

Parameters:
out - output stream
Throws:
java.io.IOException