package meerkat.bulletinboard;

import meerkat.crypto.Digest;
import meerkat.protobuf.BulletinBoardApi.*;

import java.util.List;

/**
 * Created by Arbel Deutsch Peled on 18-Dec-15.
 * Extends the Digest interface with methods for digesting Bulletin Board messages
 */
public interface BulletinBoardDigest extends Digest {

    /**
     * Update the digest with the message data (ignore the signature)
     * The digest only uses the part the signatures are computed on for this operation
     * If the message is a stub: this should be called before digesting the raw data
     * @param msg is the message that needs to be digested
     */
    public void update(BulletinBoardMessage msg);

    /**
     * Update the digest with the message data (ignore the signature)
     * The digest only uses the part the signatures are computed on for this operation
     * If the message is a stub: this should be called before digesting the raw data
     * @param msg is the message that needs to be digested
     */
    public void update(UnsignedBulletinBoardMessage msg);

}
