com.bigdata.service
Class EventReceiver.EventBTree.EventBTreeTupleSerializer

java.lang.Object
  extended by com.bigdata.btree.DefaultTupleSerializer<Long,CommitRecordIndex.Entry>
      extended by com.bigdata.service.EventReceiver.EventBTree.EventBTreeTupleSerializer
All Implemented Interfaces:
ITupleSerializer<Long,CommitRecordIndex.Entry>, IKeyBuilderFactory, Externalizable, Serializable
Enclosing class:
EventReceiver.EventBTree

protected static class EventReceiver.EventBTree.EventBTreeTupleSerializer
extends DefaultTupleSerializer<Long,CommitRecordIndex.Entry>

Encapsulates key and value formation for the EventReceiver.EventBTree.

Version:
$Id: EventReceiver.java 2547 2010-03-24 20:44:07Z thompsonbry $
Author:
Bryan Thompson
See Also:
Serialized Form

Constructor Summary
EventReceiver.EventBTree.EventBTreeTupleSerializer()
          De-serialization ctor.
EventReceiver.EventBTree.EventBTreeTupleSerializer(IKeyBuilderFactory keyBuilderFactory)
          Ctor when creating a new instance.
 
Method Summary
 Long deserializeKey(ITuple tuple)
          Decodes the key as a timestamp.
 byte[] serializeKey(Object obj)
          Return the unsigned byte[] key for a timestamp.
 
Methods inherited from class com.bigdata.btree.DefaultTupleSerializer
deserialize, getDefaultKeyBuilderFactory, getDefaultLeafKeysCoder, getDefaultValuesCoder, getKeyBuilder, getLeafKeysCoder, getLeafValuesCoder, newInstance, readExternal, serializeVal, setLeafKeysCoder, setLeafValuesCoder, toString, writeExternal
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

EventReceiver.EventBTree.EventBTreeTupleSerializer

public EventReceiver.EventBTree.EventBTreeTupleSerializer()
De-serialization ctor.


EventReceiver.EventBTree.EventBTreeTupleSerializer

public EventReceiver.EventBTree.EventBTreeTupleSerializer(IKeyBuilderFactory keyBuilderFactory)
Ctor when creating a new instance.

Parameters:
keyBuilderFactory -
Method Detail

deserializeKey

public Long deserializeKey(ITuple tuple)
Decodes the key as a timestamp.

Specified by:
deserializeKey in interface ITupleSerializer<Long,CommitRecordIndex.Entry>
Overrides:
deserializeKey in class DefaultTupleSerializer<Long,CommitRecordIndex.Entry>

serializeKey

public byte[] serializeKey(Object obj)
Return the unsigned byte[] key for a timestamp.

Specified by:
serializeKey in interface ITupleSerializer<Long,CommitRecordIndex.Entry>
Overrides:
serializeKey in class DefaultTupleSerializer<Long,CommitRecordIndex.Entry>
Parameters:
obj - A timestamp.
Returns:
An unsigned byte[] which places the object into the total sort order for the index and never null ( null keys are not allowed into an index).


Copyright © 2006-2012 SYSTAP, LLC. All Rights Reserved.