libcommonc++  0.7
SHA1Digest Class Reference

A class for generating SHA-1 digests. More...

#include <SHA1Digest.h++>

Inheritance diagram for SHA1Digest:
Collaboration diagram for SHA1Digest:

Public Member Functions

 SHA1Digest ()
 Construct a new SHA1Digest. More...
 
virtual ~SHA1Digest ()
 Destructor. More...
 
virtual size_t size () const
 Return the size of the digest generated by this class, in bytes. More...
 
virtual void update (const byte_t *buf, size_t len)
 Update the digest with more data. More...
 
virtual void finish (byte_t *digest)
 Finish generating the digest. More...
 
virtual void reset ()
 Reset the object for a new digest. More...
 

Detailed Description

A class for generating SHA-1 digests.

Author
Mark Lindner

Constructor & Destructor Documentation

◆ SHA1Digest()

Construct a new SHA1Digest.

◆ ~SHA1Digest()

~SHA1Digest ( )
virtual

Destructor.

Member Function Documentation

◆ finish()

void finish ( byte_t digest)
virtual

Finish generating the digest.

Parameters
digestThe array into which to store the digest. This array must be at least the length returned by size().

Implements Digest.

◆ reset()

void reset ( )
virtual

Reset the object for a new digest.

Implements Digest.

◆ size()

virtual size_t size ( ) const
inlinevirtual

Return the size of the digest generated by this class, in bytes.

Implements Digest.

◆ update()

void update ( const byte_t buf,
size_t  len 
)
virtual

Update the digest with more data.

Parameters
bufA pointer to the data.
lenThe length of the data.
Exceptions
IOExceptionIf the maximum length of data that this class can compute a digest for would be exceeded by this call.

Implements Digest.


The documentation for this class was generated from the following files: