public final class

DateSerializer

extends AbstractSerializer<T>
java.lang.Object
   ↳ com.netflix.astyanax.serializers.AbstractSerializer<T>
     ↳ com.netflix.astyanax.serializers.DateSerializer

Class Overview

Converts bytes to Date and vice versa, by first converting the Date to or from a long which represents the specified number of milliseconds since the standard base time known as "the Unix epoch", that is January 1, 1970, 00:00:00 UTC.

See Also

Summary

Public Constructors
DateSerializer()
Public Methods
Date fromByteBuffer(ByteBuffer bytes)
Extract an object of type T from the bytes.
ByteBuffer fromString(String str)
Create a ByteBuffer by first parsing the type out of a string
static DateSerializer get()
ByteBuffer getNext(ByteBuffer byteBuffer)
Return the byte buffer for the next value in sorted order for the matching comparator type.
String getString(ByteBuffer byteBuffer)
ByteBuffer toByteBuffer(Date obj)
Extract bytes from the obj of type T
[Expand]
Inherited Methods
From class com.netflix.astyanax.serializers.AbstractSerializer
From class java.lang.Object
From interface com.netflix.astyanax.Serializer

Public Constructors

public DateSerializer ()

Public Methods

public Date fromByteBuffer (ByteBuffer bytes)

Extract an object of type T from the bytes.

public ByteBuffer fromString (String str)

Create a ByteBuffer by first parsing the type out of a string

public static DateSerializer get ()

public ByteBuffer getNext (ByteBuffer byteBuffer)

Return the byte buffer for the next value in sorted order for the matching comparator type. This is used for paginating columns.

public String getString (ByteBuffer byteBuffer)

public ByteBuffer toByteBuffer (Date obj)

Extract bytes from the obj of type T