org.knime.core.data.date
Class DateAndTimeCellSerializer

java.lang.Object
  extended by org.knime.core.data.date.DateAndTimeCellSerializer
All Implemented Interfaces:
DataCellSerializer<DateAndTimeCell>, SerializerMethodLoader.Serializer<DateAndTimeCell>

 class DateAndTimeCellSerializer
extends Object
implements DataCellSerializer<DateAndTimeCell>

Serializes a DateAndTimeCell by writing the long representing the UTC time and the booleans whether date, time, or milliseconds are available.

Author:
Fabian Dill, KNIME.com, Zurich, Switzerland

Constructor Summary
DateAndTimeCellSerializer()
           
 
Method Summary
 DateAndTimeCell deserialize(DataCellDataInput input)
          Loads a new instance of DataCell of type T from the input stream, which represents a former serialized DataCell content.
 void serialize(DateAndTimeCell cell, DataCellDataOutput output)
          Saves the cell to the output stream.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DateAndTimeCellSerializer

DateAndTimeCellSerializer()
Method Detail

deserialize

public DateAndTimeCell deserialize(DataCellDataInput input)
                            throws IOException
Loads a new instance of DataCell of type T from the input stream, which represents a former serialized DataCell content.

Specified by:
deserialize in interface DataCellSerializer<DateAndTimeCell>
Parameters:
input - the source to load from, never null
Returns:
a new DataValue instance of type T representing a former serialized DataCell
Throws:
IOException - if loading fails

serialize

public void serialize(DateAndTimeCell cell,
                      DataCellDataOutput output)
               throws IOException
Saves the cell to the output stream.

Specified by:
serialize in interface DataCellSerializer<DateAndTimeCell>
Parameters:
cell - the DataCell to save
output - the place to write to
Throws:
IOException - if writing fails


Copyright, 2003 - 2010. All rights reserved.
University of Konstanz, Germany.
Chair for Bioinformatics and Information Mining, Prof. Dr. Michael R. Berthold.
You may not modify, publish, transmit, transfer or sell, reproduce, create derivative works from, distribute, perform, display, or in any way exploit any of the content, in whole or in part, except as otherwise expressly permitted in writing by the copyright owner or as specified in the license file distributed with this product.