me.prettyprint.cassandra.serializers
Class BooleanSerializer

java.lang.Object
  extended by me.prettyprint.cassandra.serializers.AbstractSerializer<Boolean>
      extended by me.prettyprint.cassandra.serializers.BooleanSerializer
All Implemented Interfaces:
Serializer<Boolean>

public final class BooleanSerializer
extends AbstractSerializer<Boolean>

Converts bytes to Boolean and vice versa

Author:
Bozhidar Bozhanov

Constructor Summary
BooleanSerializer()
           
 
Method Summary
 Boolean fromByteBuffer(ByteBuffer bytes)
          Extract an object of type T from the bytes.
static BooleanSerializer get()
           
 ByteBuffer toByteBuffer(Boolean obj)
          Extract bytes from the obj of type T
 
Methods inherited from class me.prettyprint.cassandra.serializers.AbstractSerializer
computeInitialHashSize, fromBytes, fromBytesList, fromBytesMap, fromBytesSet, getComparatorType, toBytes, toBytesList, toBytesMap, toBytesSet
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BooleanSerializer

public BooleanSerializer()
Method Detail

get

public static BooleanSerializer get()

toByteBuffer

public ByteBuffer toByteBuffer(Boolean obj)
Description copied from interface: Serializer
Extract bytes from the obj of type T

Specified by:
toByteBuffer in interface Serializer<Boolean>
Specified by:
toByteBuffer in class AbstractSerializer<Boolean>
Returns:

fromByteBuffer

public Boolean fromByteBuffer(ByteBuffer bytes)
Description copied from interface: Serializer
Extract an object of type T from the bytes.

Specified by:
fromByteBuffer in interface Serializer<Boolean>
Specified by:
fromByteBuffer in class AbstractSerializer<Boolean>
Returns:


Copyright © 2011. All Rights Reserved.