Class Point2DSerializer
- java.lang.Object
-
- org.pentaho.reporting.libraries.serializer.methods.Point2DSerializer
-
- All Implemented Interfaces:
SerializeMethod
public class Point2DSerializer extends java.lang.Object implements SerializeMethod
A SerializeMethod implementation that handles Point2D objects.- Author:
- Thomas Morgner
- See Also:
Point2D
-
-
Constructor Summary
Constructors Constructor Description Point2DSerializer()Default Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.ClassgetObjectClass()Returns the class of the object, which this object can serialize.java.lang.ObjectreadObject(java.io.ObjectInputStream in)Reads the object from the object input stream.voidwriteObject(java.lang.Object o, java.io.ObjectOutputStream out)Writes a serializable object description to the given object output stream.
-
-
-
Method Detail
-
writeObject
public void writeObject(java.lang.Object o, java.io.ObjectOutputStream out) throws java.io.IOExceptionWrites a serializable object description to the given object output stream.- Specified by:
writeObjectin interfaceSerializeMethod- Parameters:
o- the to be serialized object.out- the outputstream that should receive the object.- Throws:
java.io.IOException- if an I/O error occured.
-
readObject
public java.lang.Object readObject(java.io.ObjectInputStream in) throws java.io.IOException, java.lang.ClassNotFoundExceptionReads the object from the object input stream.- Specified by:
readObjectin interfaceSerializeMethod- Parameters:
in- the object input stream from where to read the serialized data.- Returns:
- the generated object.
- Throws:
java.io.IOException- if reading the stream failed.java.lang.ClassNotFoundException- if serialized object class cannot be found.
-
getObjectClass
public java.lang.Class getObjectClass()
Returns the class of the object, which this object can serialize.- Specified by:
getObjectClassin interfaceSerializeMethod- Returns:
- the class of java.awt.geom.Point2D.
-
-