src/java/org/apache/cassandra/tools/SSTableExport.java
/**
     * Serialize a given column to the JSON format
     *
     * @param column column presentation
     * @param comparator columns comparator
     * @param cfMetaData Column Family metadata (to get validator)
     *
     * @return column as serialized list
     */
Serialize a given column to the JSON format
@param column column presentation
@param comparator columns comparator
@param cfMetaData Column Family metadata (to get validator)

@return column as serialized list
Serialize a given column to the JSON format @param column column presentation @param comparator columns comparator @param cfMetaData Column Family metadata ( to get validator ) @return column as serialized list
private static List<Object> serializeColumn(IColumn column, AbstractType comparator, CFMetaData cfMetaData)
    {
        ArrayList<Object> serializedColumn = new ArrayList<Object>();
        ByteBuffer name = ByteBufferUtil.clone(column.name());
        ByteBuffer value = ByteBufferUtil.clone(column.value());
        serializedColumn.add(comparator.getString(name));
        if (column instanceof DeletedColumn)
        {
            serializedColumn.add(ByteBufferUtil.bytesToHex(value));
        }
        else
        {
            AbstractType validator = cfMetaData.getValueValidator(name);
            serializedColumn.add(validator.getString(value));
        }
        serializedColumn.add(column.timestamp());
        if (column instanceof DeletedColumn)
        {
            serializedColumn.add("d");
        }
        else if (column instanceof ExpiringColumn)
        {
            serializedColumn.add("e");
            serializedColumn.add(((ExpiringColumn) column).getTimeToLive());
            serializedColumn.add(column.getLocalDeletionTime());
        }
        else if (column instanceof CounterColumn)
        {
            serializedColumn.add("c");
            serializedColumn.add(((CounterColumn) column).timestampOfLastDelete());
        }
        return serializedColumn;
    }
private static List < Object > serializeColumn ( IColumn column , AbstractType comparator , CFMetaData cfMetaData ) { ArrayList < Object > serializedColumn = new ArrayList < Object > ( ) ; ByteBuffer name = ByteBufferUtil . clone ( column . name ( ) ) ; ByteBuffer value = ByteBufferUtil . clone ( column . value ( ) ) ; serializedColumn . add ( comparator . getString ( name ) ) ; if ( column instanceof DeletedColumn ) { serializedColumn . add ( ByteBufferUtil . bytesToHex ( value ) ) ; } else { AbstractType validator = cfMetaData . getValueValidator ( name ) ; serializedColumn . add ( validator . getString ( value ) ) ; } serializedColumn . add ( column . timestamp ( ) ) ; if ( column instanceof DeletedColumn ) { serializedColumn . add ( "d" ) ; } else if ( column instanceof ExpiringColumn ) { serializedColumn . add ( "e" ) ; serializedColumn . add ( ( ( ExpiringColumn ) column ) . getTimeToLive ( ) ) ; serializedColumn . add ( column . getLocalDeletionTime ( ) ) ; } else if ( column instanceof CounterColumn ) { serializedColumn . add ( "c" ) ; serializedColumn . add ( ( ( CounterColumn ) column ) . timestampOfLastDelete ( ) ) ; } return serializedColumn ; }
Serialize a given column to the JSON format
 @param column column presentation
 @param comparator columns comparator
 @param cfMetaData Column Family metadata (to get validator)
Serialize a given column to the JSON format @param column column presentation @param comparator columns comparator @param cfMetaData Column Family metadata ( to get validator )