ROSE 0.11.145.147
Public Member Functions | List of all members
Rose::Combinatorics::HasherFnv Class Reference

Description

Fowler-Noll-Vo hashing using the Hasher interface.

Definition at line 458 of file Combinatorics.h.

#include <roseSupport/Combinatorics.h>

Inheritance diagram for Rose::Combinatorics::HasherFnv:
Inheritance graph
[legend]
Collaboration diagram for Rose::Combinatorics::HasherFnv:
Collaboration graph
[legend]

Public Member Functions

const Digestdigest () override
 Return the digest.
 
void append (const uint8_t *message, size_t messageSize) override
 Insert data into the digest.
 
uint64_t partial () const
 
- Public Member Functions inherited from Rose::Combinatorics::Hasher
virtual void clear ()
 Reset the hasher to its initial state.
 
std::string toString ()
 String representation of the digest.
 
void print (std::ostream &)
 Print a hash to a stream.
 
void insert (const std::string &x)
 Insert data into the digest.
 
void insert (uint64_t x)
 Insert data into the digest.
 
void insert (const uint8_t *x, size_t size)
 Insert data into the digest.
 
void insert (const std::vector< uint8_t > &v)
 Insert data into the digest.
 
void insert (std::istream &stream)
 Insert data into the digest.
 
uint64_t make64Bits ()
 Returns the hash as a 64 bit int.
 
uint64_t make64Bits (const Digest &)
 Returns the hash as a 64 bit int.
 

Additional Inherited Members

- Public Types inherited from Rose::Combinatorics::Hasher
typedef std::vector< uint8_t > Digest
 The digest of the input message.
 
- Static Public Member Functions inherited from Rose::Combinatorics::Hasher
static std::string toString (const Digest &)
 Convert a digest to a hexadecimal string.
 
- Protected Attributes inherited from Rose::Combinatorics::Hasher
Digest digest_
 

Constructor & Destructor Documentation

◆ HasherFnv()

Rose::Combinatorics::HasherFnv::HasherFnv ( )
inline

Definition at line 461 of file Combinatorics.h.

Member Function Documentation

◆ digest()

const Digest & Rose::Combinatorics::HasherFnv::digest ( )
overridevirtual

Return the digest.

Finalizes the hash function and returns the digest for all the input. Additional input should not be inserted after this function is called since some hash functions don't support this.

Reimplemented from Rose::Combinatorics::Hasher.

◆ append()

void Rose::Combinatorics::HasherFnv::append ( const uint8_t *  message,
size_t  messageSize 
)
overridevirtual

Insert data into the digest.

This is the lowest level method of inserting new message content into the digest. This can be called as often as desired, building a digest incrementally.

Implements Rose::Combinatorics::Hasher.

◆ partial()

uint64_t Rose::Combinatorics::HasherFnv::partial ( ) const
inline

Definition at line 464 of file Combinatorics.h.


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