ostore.util
Interface Digestible

All Superinterfaces:
QuickSerializable
All Known Subinterfaces:
QSPrivateKey, QSPublicKey, SecureHash, SecureVerify, VerifiableBlock
All Known Implementing Classes:
NodeId, QSInt, QSLong, QSString, SignedQS, STSVerify, TapestryLocateMsg, TapestryRouteMsg, QSBool, QSByteArray, QSDate, QSArray, VID, SigShare, KeyShare

public interface Digestible
extends QuickSerializable

An interface for classes which understand how to use SecureHashBuffers to hash themselves.

The default method for hashing QuickSerializable objects is to serialize the object and hash the resulting byte array. SecureHashBuffers allow objects to incrementally update the hash's internal digest, eliminating much of the copying involved in serialization. The reduced overhead should be noticeable for large, mostly pre-serialized objects, such as data blocks.

Version:
$Id: Digestible.java,v 1.3 2002/03/29 00:24:00 srhea Exp $
Author:
Dennis Geels

Method Summary
 void add_to_digest(SecureHashBuffer buffer)
          Adds this object's state to the specified SecureHashBuffer using the various add methods.
 
Methods inherited from interface ostore.util.QuickSerializable
to_bytes, type_code
 

Method Detail

add_to_digest

public void add_to_digest(SecureHashBuffer buffer)
Adds this object's state to the specified SecureHashBuffer using the various add methods.
See Also:
SecureHashBuffer.add( byte ), SecureHashBuffer.add( byte[] ), SecureHashBuffer.add( byte[], int, int ), SecureHashBuffer.add( Digestible )