me.prettyprint.cassandra.serializers
Class DoubleSerializer
java.lang.Object
me.prettyprint.cassandra.serializers.AbstractSerializer<Double>
me.prettyprint.cassandra.serializers.DoubleSerializer
- All Implemented Interfaces:
- Serializer<Double>
public class DoubleSerializer
- extends AbstractSerializer<Double>
Uses LongSerializer via translating Doubles to and from raw long bytes form.
- Author:
- Yuri Finkelstein
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DoubleSerializer
public DoubleSerializer()
get
public static DoubleSerializer get()
toByteBuffer
public ByteBuffer toByteBuffer(Double obj)
- Description copied from interface:
Serializer
- Extract bytes from the obj of type T
- Specified by:
toByteBuffer
in interface Serializer<Double>
- Specified by:
toByteBuffer
in class AbstractSerializer<Double>
- Returns:
fromByteBuffer
public Double fromByteBuffer(ByteBuffer bytes)
- Description copied from interface:
Serializer
- Extract an object of type T from the bytes.
- Specified by:
fromByteBuffer
in interface Serializer<Double>
- Specified by:
fromByteBuffer
in class AbstractSerializer<Double>
- Returns:
Copyright © 2011. All Rights Reserved.