Package ej.sp
Interface SPWriter
-
public interface SPWriterTheSPWriterinterface provides a method for serializing objects into a block.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidwriteObject(ShieldedPlug sp, int blockID, Object o)Writes an object into a block of the givenShieldedPlug.
-
-
-
Method Detail
-
writeObject
void writeObject(ShieldedPlug sp, int blockID, Object o)
Writes an object into a block of the givenShieldedPlug. The class implementing this interface defines how the object is written.- Parameters:
sp- theShieldedPluginto which data is writtenblockID- ID of the blocko- the object to be written- Throws:
IllegalArgumentException- if no block is defined with the given IDIndexOutOfBoundsException- if the block length is lower than the size needed for object serialization
-
-