private static List < Object > serializeColumn ( Cell cell , CFMetaData cfMetaData ) { CellNameType comparator = cfMetaData . comparator ; ArrayList < Object > serializedColumn = new ArrayList < Object > ( ) ; serializedColumn . add ( comparator . getString ( cell . name ( ) ) ) ; if ( cell instanceof DeletedCell ) { serializedColumn . add ( cell . getLocalDeletionTime ( ) ) ; } else { AbstractType < ? > validator = cfMetaData . getValueValidator ( cell . name ( ) ) ; serializedColumn . add ( validator . getString ( cell . value ( ) ) ) ; } serializedColumn . add ( cell . timestamp ( ) ) ; if ( cell instanceof DeletedCell ) { serializedColumn . add ( "d" ) ; } else if ( cell instanceof ExpiringCell ) { serializedColumn . add ( "e" ) ; serializedColumn . add ( ( ( ExpiringCell ) cell ) . getTimeToLive ( ) ) ; serializedColumn . add ( cell . getLocalDeletionTime ( ) ) ; } else if ( cell instanceof CounterCell ) { serializedColumn . add ( "c" ) ; serializedColumn . add ( ( ( CounterCell ) cell ) . timestampOfLastDelete ( ) ) ; } return serializedColumn ; }
Serialize a given cell to a List of Objects that jsonMapper knows how to turn into strings . Format is