Tan D Nguyen > Digest-Pearson-PurePerl-1.00 > Digest::Pearson::PurePerl

Download:
Digest-Pearson-PurePerl-1.00.tar.gz

Dependencies

Annotate this POD

CPAN RT

Open  0
Report a bug
Module Version: 1.00   Source  

NAME ^

Digest::Pearson::PurePerl - Pure Perl interface to Pearson hash

SYNOPSIS ^

  use Digest::Pearson::PurePerl qw(pearson);

  my $hash = pearson("abcdef012345");  # 0 <= $hash < 256

DESCRIPTION ^

Digest::Pearson::PurePerl is an implementation of Peter K. Pearson's hash algorithm presented in "Fast Hashing of Variable Length Text Strings" - ACM 1990. This hashing technique yields good distribution of hashed results for variable length input strings on the range 0-255, and thus, it is well suited for data load balancing.

If you prefer a fast implementation, you might want to consider Digest::Pearson instead.

This module does not export anything by default. To use this hash function, do either of the following.

use Digest::Pearson qw(pearson);

Digest::Pearson::pearson($string)

ACKNOWLEDGEMENTS ^

The implementation is derived from RFC 3074 - DHC Load Balancing Algorithm.

SEE ALSO ^

Digest::Pearson, Digest::FNV, Digest::DJB.

BUGS ^

If you find any inaccurate or missing information, please send your comments to tnguyen@cpan.org. Your effort is certainly appreciated!