org.apache.cassandra.db

## Class ColumnFamilySerializer

- java.lang.Object
- - org.apache.cassandra.db.ColumnFamilySerializer

- All Implemented Interfaces:
    ISSTableSerializer<ColumnFamily>, IVersionedSerializer<ColumnFamily>

      public class ColumnFamilySerializer
      extends java.lang.Object
      implements IVersionedSerializer<ColumnFamily>, ISSTableSerializer<ColumnFamily>

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ColumnFamilySerializer()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `int` | `cfIdSerializedSize(java.util.UUID cfId, TypeSizes typeSizes, int version)`
    `long` | `contentSerializedSize(ColumnFamily cf, TypeSizes typeSizes, int version)`
    `ColumnFamily` | `deserialize(java.io.DataInput in, ColumnFamily.Factory factory, ColumnSerializer.Flag flag, int version)`
    `ColumnFamily` | `deserialize(java.io.DataInput in, ColumnSerializer.Flag flag, int version)`
    `ColumnFamily` | `deserialize(java.io.DataInput in, int version)` Deserialize into the specified DataInputStream instance.
    `java.util.UUID` | `deserializeCfId(java.io.DataInput in, int version)`
    `ColumnFamily` | `deserializeFromSSTable(java.io.DataInput in, Version version)` Deserialize into the specified DataInputStream instance in the format suited for SSTables.
    `void` | `serialize(ColumnFamily cf, DataOutputPlus out, int version)` Serialize the specified type into the specified DataOutputStream instance.
    `void` | `serializeCfId(java.util.UUID cfId, DataOutputPlus out, int version)`
    `long` | `serializedSize(ColumnFamily cf, int version)` Calculate serialized size of object without actually serializing.
    `long` | `serializedSize(ColumnFamily cf, TypeSizes typeSizes, int version)`
    `void` | `serializeForSSTable(ColumnFamily cf, DataOutputPlus out)` Serialize the specified type into the specified DataOutputStream instance in the format suited for SSTables.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### ColumnFamilySerializer

          public ColumnFamilySerializer()

  - ### Method Detail

    - #### serialize

          public void serialize(ColumnFamily cf,
                                DataOutputPlus out,
                                int version)

      Description copied from interface: `IVersionedSerializer`
      Serialize the specified type into the specified DataOutputStream instance.
      Specified by:
        `serialize` in interface `IVersionedSerializer<ColumnFamily>`
      Parameters:
        `cf` - type that needs to be serialized
        `out` - DataOutput into which serialization needs to happen.
        `version` - protocol version

    - #### deserialize

          public ColumnFamily deserialize(java.io.DataInput in,
                                          int version)
                                   throws java.io.IOException

      Description copied from interface: `IVersionedSerializer`
      Deserialize into the specified DataInputStream instance.
      Specified by:
        `deserialize` in interface `IVersionedSerializer<ColumnFamily>`
      Parameters:
        `in` - DataInput from which deserialization needs to happen.
        `version` - protocol version
      Returns:
        the type that was deserialized
      Throws:
        `java.io.IOException` - if deserialization fails

    - #### deserialize

          public ColumnFamily deserialize(java.io.DataInput in,
                                          ColumnSerializer.Flag flag,
                                          int version)
                                   throws java.io.IOException

      Throws:
        `java.io.IOException`

    - #### deserialize

          public ColumnFamily deserialize(java.io.DataInput in,
                                          ColumnFamily.Factory factory,
                                          ColumnSerializer.Flag flag,
                                          int version)
                                   throws java.io.IOException

      Throws:
        `java.io.IOException`

    - #### contentSerializedSize

          public long contentSerializedSize(ColumnFamily cf,
                                            TypeSizes typeSizes,
                                            int version)

    - #### serializedSize

          public long serializedSize(ColumnFamily cf,
                                     TypeSizes typeSizes,
                                     int version)

    - #### serializedSize

          public long serializedSize(ColumnFamily cf,
                                     int version)

      Description copied from interface: `IVersionedSerializer`
      Calculate serialized size of object without actually serializing.
      Specified by:
        `serializedSize` in interface `IVersionedSerializer<ColumnFamily>`
      Parameters:
        `cf` - object to calculate serialized size
        `version` - protocol version
      Returns:
        serialized size of object t

    - #### serializeForSSTable

          public void serializeForSSTable(ColumnFamily cf,
                                          DataOutputPlus out)

      Description copied from interface: `ISSTableSerializer`
      Serialize the specified type into the specified DataOutputStream instance in the format suited for SSTables.
      Specified by:
        `serializeForSSTable` in interface `ISSTableSerializer<ColumnFamily>`
      Parameters:
        `cf` - type that needs to be serialized
        `out` - DataOutput into which serialization needs to happen.

    - #### deserializeFromSSTable

          public ColumnFamily deserializeFromSSTable(java.io.DataInput in,
                                                     Version version)

      Description copied from interface: `ISSTableSerializer`
      Deserialize into the specified DataInputStream instance in the format suited for SSTables.
      Specified by:
        `deserializeFromSSTable` in interface `ISSTableSerializer<ColumnFamily>`
      Parameters:
        `in` - DataInput from which deserialization needs to happen.
        `version` - the version for the sstable we're reading from
      Returns:
        the type that was deserialized

    - #### serializeCfId

          public void serializeCfId(java.util.UUID cfId,
                                    DataOutputPlus out,
                                    int version)
                             throws java.io.IOException

      Throws:
        `java.io.IOException`

    - #### deserializeCfId

          public java.util.UUID deserializeCfId(java.io.DataInput in,
                                                int version)
                                         throws java.io.IOException

      Throws:
        `java.io.IOException`

    - #### cfIdSerializedSize

          public int cfIdSerializedSize(java.util.UUID cfId,
                                        TypeSizes typeSizes,
                                        int version)

Copyright © 2018 The Apache Software Foundation