Interface ISerializationConverter<T>
-
- Type Parameters:
T- Type to be read and written
public interface ISerializationConverter<T>Interface to be implemented to read and write objects.- Author:
- Philip Helger
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description TreadConvertedObject(ObjectInputStream aOIS)Read the object from the specifiedObjectInputStream.voidwriteConvertedObject(T aSourceObject, ObjectOutputStream aOOS)Write the passed source object to the passedObjectOutputStream.
-
-
-
Method Detail
-
writeConvertedObject
void writeConvertedObject(@Nonnull T aSourceObject, @Nonnull ObjectOutputStream aOOS) throws IOException
Write the passed source object to the passedObjectOutputStream.- Parameters:
aSourceObject- The source object to write. Nevernull.aOOS- The output stream to write to. Nevernull.- Throws:
IOException- In case of a stream error
-
readConvertedObject
@Nonnull T readConvertedObject(@Nonnull ObjectInputStream aOIS) throws IOException
Read the object from the specifiedObjectInputStream.- Parameters:
aOIS- The object input stream to read from. Nevernull.- Returns:
- The read object. May not be
null. - Throws:
IOException- In case of a stream error
-
-