Class ThriftObjectSizeUtils
- java.lang.Object
-
- com.palantir.atlasdb.keyvalue.cassandra.thrift.ThriftObjectSizeUtils
-
public final class ThriftObjectSizeUtils extends Object
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static long
getApproximateSizeOfColListsByKey(Map<ByteBuffer,List<List<org.apache.cassandra.thrift.ColumnOrSuperColumn>>> result)
static long
getApproximateSizeOfColsByKey(Map<ByteBuffer,List<org.apache.cassandra.thrift.ColumnOrSuperColumn>> result)
static long
getApproximateSizeOfKeySlices(List<org.apache.cassandra.thrift.KeySlice> slices)
static long
getApproximateSizeOfMutationMap(Map<ByteBuffer,Map<String,List<org.apache.cassandra.thrift.Mutation>>> batchMutateMap)
static long
getByteBufferSize(ByteBuffer byteBuffer)
static long
getCasByteCount(List<org.apache.cassandra.thrift.Column> updates)
static <T> long
getCollectionSize(Collection<T> collection, ToLongFunction<T> sizeFunction)
static long
getColumnOrSuperColumnSize(org.apache.cassandra.thrift.ColumnOrSuperColumn columnOrSuperColumn)
static long
getColumnSize(org.apache.cassandra.thrift.Column column)
static long
getCqlResultSize(org.apache.cassandra.thrift.CqlResult cqlResult)
static long
getKeySliceSize(org.apache.cassandra.thrift.KeySlice keySlice)
static long
getMutationSize(org.apache.cassandra.thrift.Mutation mutation)
static Map<String,Long>
getSizeOfMutationPerTable(Map<ByteBuffer,Map<String,List<org.apache.cassandra.thrift.Mutation>>> batchMutateMap)
static long
getStringSize(String string)
-
-
-
Method Detail
-
getApproximateSizeOfMutationMap
public static long getApproximateSizeOfMutationMap(Map<ByteBuffer,Map<String,List<org.apache.cassandra.thrift.Mutation>>> batchMutateMap)
-
getSizeOfMutationPerTable
public static Map<String,Long> getSizeOfMutationPerTable(Map<ByteBuffer,Map<String,List<org.apache.cassandra.thrift.Mutation>>> batchMutateMap)
-
getApproximateSizeOfColsByKey
public static long getApproximateSizeOfColsByKey(Map<ByteBuffer,List<org.apache.cassandra.thrift.ColumnOrSuperColumn>> result)
-
getApproximateSizeOfColListsByKey
public static long getApproximateSizeOfColListsByKey(Map<ByteBuffer,List<List<org.apache.cassandra.thrift.ColumnOrSuperColumn>>> result)
-
getApproximateSizeOfKeySlices
public static long getApproximateSizeOfKeySlices(List<org.apache.cassandra.thrift.KeySlice> slices)
-
getCasByteCount
public static long getCasByteCount(List<org.apache.cassandra.thrift.Column> updates)
-
getColumnOrSuperColumnSize
public static long getColumnOrSuperColumnSize(org.apache.cassandra.thrift.ColumnOrSuperColumn columnOrSuperColumn)
-
getByteBufferSize
public static long getByteBufferSize(ByteBuffer byteBuffer)
-
getMutationSize
public static long getMutationSize(org.apache.cassandra.thrift.Mutation mutation)
-
getCqlResultSize
public static long getCqlResultSize(org.apache.cassandra.thrift.CqlResult cqlResult)
-
getKeySliceSize
public static long getKeySliceSize(org.apache.cassandra.thrift.KeySlice keySlice)
-
getStringSize
public static long getStringSize(String string)
-
getColumnSize
public static long getColumnSize(org.apache.cassandra.thrift.Column column)
-
getCollectionSize
public static <T> long getCollectionSize(@Nullable Collection<T> collection, ToLongFunction<T> sizeFunction)
-
-