com.netflix.astyanax.serializers
Class ByteSerializer

java.lang.Object
  extended by com.netflix.astyanax.serializers.AbstractSerializer<java.lang.Byte>
      extended by com.netflix.astyanax.serializers.ByteSerializer
All Implemented Interfaces:
Serializer<java.lang.Byte>

public class ByteSerializer
extends AbstractSerializer<java.lang.Byte>


Constructor Summary
ByteSerializer()
           
 
Method Summary
 java.lang.Byte fromByteBuffer(java.nio.ByteBuffer byteBuffer)
          Extract an object of type T from the bytes.
 java.nio.ByteBuffer fromString(java.lang.String str)
          Create a ByteBuffer by first parsing the type out of a string
static ByteSerializer get()
           
 java.nio.ByteBuffer getNext(java.nio.ByteBuffer byteBuffer)
          Return the byte buffer for the next value in sorted order for the matching comparator type.
 java.lang.String getString(java.nio.ByteBuffer byteBuffer)
           
 java.nio.ByteBuffer toByteBuffer(java.lang.Byte obj)
          Extract bytes from the obj of type T
 
Methods inherited from class com.netflix.astyanax.serializers.AbstractSerializer
computeInitialHashSize, fromBytes, fromBytesList, fromBytesMap, fromBytesSet, getComparatorType, toBytes, toBytesList, toBytesList, toBytesList, toBytesMap, toBytesSet
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ByteSerializer

public ByteSerializer()
Method Detail

get

public static ByteSerializer get()

toByteBuffer

public java.nio.ByteBuffer toByteBuffer(java.lang.Byte obj)
Description copied from interface: Serializer
Extract bytes from the obj of type T

Specified by:
toByteBuffer in interface Serializer<java.lang.Byte>
Specified by:
toByteBuffer in class AbstractSerializer<java.lang.Byte>
Returns:

fromByteBuffer

public java.lang.Byte fromByteBuffer(java.nio.ByteBuffer byteBuffer)
Description copied from interface: Serializer
Extract an object of type T from the bytes.

Specified by:
fromByteBuffer in interface Serializer<java.lang.Byte>
Specified by:
fromByteBuffer in class AbstractSerializer<java.lang.Byte>
Returns:

fromString

public java.nio.ByteBuffer fromString(java.lang.String str)
Description copied from interface: Serializer
Create a ByteBuffer by first parsing the type out of a string

Specified by:
fromString in interface Serializer<java.lang.Byte>
Overrides:
fromString in class AbstractSerializer<java.lang.Byte>
Returns:

getString

public java.lang.String getString(java.nio.ByteBuffer byteBuffer)
Specified by:
getString in interface Serializer<java.lang.Byte>
Overrides:
getString in class AbstractSerializer<java.lang.Byte>

getNext

public java.nio.ByteBuffer getNext(java.nio.ByteBuffer byteBuffer)
Description copied from interface: Serializer
Return the byte buffer for the next value in sorted order for the matching comparator type. This is used for paginating columns.

Specified by:
getNext in interface Serializer<java.lang.Byte>
Overrides:
getNext in class AbstractSerializer<java.lang.Byte>
Returns: