org.apache.directory.server.core.partition.impl.btree.jdbm
Class IndexValueSerializer

java.lang.Object
  extended by org.apache.directory.server.core.partition.impl.btree.jdbm.IndexValueSerializer
All Implemented Interfaces:
java.io.Serializable, Serializer

public class IndexValueSerializer
extends java.lang.Object
implements Serializer

Version:
$Rev$, $Date$
Author:
Apache Directory Project
See Also:
Serialized Form

Constructor Summary
IndexValueSerializer()
           
 
Method Summary
 java.lang.Object deserialize(byte[] serialized)
          Deserialize the content of an object from a byte array.
 byte[] serialize(java.lang.Object obj)
          Serialize the object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

IndexValueSerializer

public IndexValueSerializer()
Method Detail

deserialize

public java.lang.Object deserialize(byte[] serialized)
                             throws java.io.IOException
Description copied from interface: Serializer
Deserialize the content of an object from a byte array.

Specified by:
deserialize in interface Serializer
Parameters:
serialized - Byte array representation of the object
Returns:
deserialized object
Throws:
java.io.IOException

serialize

public byte[] serialize(java.lang.Object obj)
                 throws java.io.IOException
Serialize the object. It can be a long, a BTree or an AvlTree

Specified by:
serialize in interface Serializer
Parameters:
obj - The object to serialize
Returns:
a byte[] containing the serialized value
Throws:
java.io.IOException - If the serialization failed


Copyright © 2003-2011 Apache Software Foundation. All Rights Reserved.