it.unimi.dsi.io
Interface OfflineIterable.Serializer<A,B extends A>

Enclosing class:
OfflineIterable<T,U extends T>

public static interface OfflineIterable.Serializer<A,B extends A>

Determines a strategy to serialize and deserialize elements.


Method Summary
 void read(DataInput dis, B x)
          Reads an element.
 void write(A x, DataOutput dos)
          Writes out an element.
 

Method Detail

write

void write(A x,
           DataOutput dos)
           throws IOException
Writes out an element.

Parameters:
x - the element to be written.
dos - the stream where the element should be written.
Throws:
IOException - if an exception occurs while writing.

read

void read(DataInput dis,
          B x)
          throws IOException
Reads an element.

Parameters:
dis - the stream whence the element should be read.
x - the object where the element will be read.
Throws:
IOException - if an exception occurs while reading.