<?php
/**
* Message digest interface definition.
* This interface will set the functions that a message digester must implement.
*
* @author Marius Zadara <marius@zadara.org>
* @category org.zadara.marius.messagedigester.interfaces
* @copyright (C) 2008, Marius Zadara <marius@zadara.org>
* @license GNU GPL
* @package org.zadara.marius.messagedigester
* @access public
*/
interface IMessagedigest
{
/**
* Get an instance of a hash algorithm.
*
* @param String $hashAlgorithmName The name of the hash algorithm
* @access public
*/
public function getInstance($hashAlgorithmName);
/**
* Reset the message digest internal data.
*
* @access public
*/
public function reset();
/**
* Function to set the text for digest.
*
* @param String $text The text to digest later
*/
public function update($text);
/**
* Digest main function.
*
* @return string The text digested
*/
public function digest();
}
?>
|