Package patterntesting.runtime.io
Class BinarySerializer
- java.lang.Object
-
- patterntesting.runtime.io.AbstractSerializer
-
- patterntesting.runtime.io.BinarySerializer
-
public final class BinarySerializer extends AbstractSerializer
This is the default serializer which uses the default mechanism proved by the JDK. For this reason the serialized object must beSerializable
.- Since:
- 1.4 (30.11.2013)
- Author:
- oliver
-
-
Constructor Summary
Constructors Constructor Description BinarySerializer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.io.ObjectInputStream
createObjectInputStream(java.io.InputStream in)
Creates theObjectInputStream
that deserializes a stream of objects from an InputStream using the default mechnism of Java.java.io.ObjectOutputStream
createObjectOutputStream(java.io.OutputStream out)
Creates theObjectOutputStream
that serializees a stream of objects to theOutputStream
using the default mechnism of Java.-
Methods inherited from class patterntesting.runtime.io.AbstractSerializer
getInstance, load, load, save, save
-
-
-
-
Method Detail
-
createObjectInputStream
public java.io.ObjectInputStream createObjectInputStream(java.io.InputStream in) throws java.io.IOException
Creates theObjectInputStream
that deserializes a stream of objects from an InputStream using the default mechnism of Java. For this reason the serialized objects must beSerializable
.- Specified by:
createObjectInputStream
in classAbstractSerializer
- Parameters:
in
- the input stream- Returns:
- the object input stream
- Throws:
java.io.IOException
- Signals that an I/O exception has occurred.
-
createObjectOutputStream
public java.io.ObjectOutputStream createObjectOutputStream(java.io.OutputStream out) throws java.io.IOException
Creates theObjectOutputStream
that serializees a stream of objects to theOutputStream
using the default mechnism of Java. For this reason the serialized objects must beSerializable
.- Specified by:
createObjectOutputStream
in classAbstractSerializer
- Parameters:
out
- the out- Returns:
- the object output stream
- Throws:
java.io.IOException
- Signals that an I/O exception has occurred.- See Also:
AbstractSerializer.createObjectOutputStream(java.io.OutputStream)
-
-