com.netflix.astyanax.serializers
Class AnnotatedCompositeSerializer<T>
java.lang.Object
com.netflix.astyanax.serializers.AbstractSerializer<T>
com.netflix.astyanax.serializers.AnnotatedCompositeSerializer<T>
- Type Parameters:
T
-
- All Implemented Interfaces:
- Serializer<T>
public class AnnotatedCompositeSerializer<T>
- extends AbstractSerializer<T>
Serializer for a Pojo annotated with Component field annotations
Serialized data is formatted as a list of components with each component
having the format: <2 byte length><0>
Methods inherited from class com.netflix.astyanax.serializers.AbstractSerializer |
computeInitialHashSize, fromBytes, fromBytesList, fromBytesMap, fromBytesSet, fromString, getNext, getString, toBytes, toBytesList, toBytesList, toBytesList, toBytesMap, toBytesSet |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
AnnotatedCompositeSerializer
public AnnotatedCompositeSerializer(java.lang.Class<T> clazz,
boolean includeParentFields)
AnnotatedCompositeSerializer
public AnnotatedCompositeSerializer(java.lang.Class<T> clazz)
AnnotatedCompositeSerializer
public AnnotatedCompositeSerializer(java.lang.Class<T> clazz,
int bufferSize)
AnnotatedCompositeSerializer
public AnnotatedCompositeSerializer(java.lang.Class<T> clazz,
int bufferSize,
boolean includeParentFields)
toByteBuffer
public java.nio.ByteBuffer toByteBuffer(T obj)
- Description copied from interface:
Serializer
- Extract bytes from the obj of type T
- Specified by:
toByteBuffer
in interface Serializer<T>
- Specified by:
toByteBuffer
in class AbstractSerializer<T>
- Returns:
fromByteBuffer
public T 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<T>
- Specified by:
fromByteBuffer
in class AbstractSerializer<T>
- Returns:
getComparatorType
public ComparatorType getComparatorType()
- Specified by:
getComparatorType
in interface Serializer<T>
- Overrides:
getComparatorType
in class AbstractSerializer<T>
buildRange
public CompositeRangeBuilder buildRange()
makeEndpoint
public <T1> RangeEndpoint makeEndpoint(T1 value,
Equality equality)