|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.getopt.util.hash.FNV1 org.getopt.util.hash.FNV132
public class FNV132
Implementation of FNV1 - a fast hash function.
This implementation uses 32-bit operations, and the values returned from
getHash()
are limited to the lower 32 bits.
Field Summary |
---|
Fields inherited from class org.getopt.util.hash.FNV1 |
---|
FNV1_32_INIT, FNV1_64_INIT, hash, INIT |
Constructor Summary | |
---|---|
FNV132()
Create a hash |
Method Summary | |
---|---|
protected long |
fnv(byte[] buf,
int offset,
int len,
long seed)
Compute the hash value. |
long |
getHash()
Retrieve the hash value |
Methods inherited from class org.getopt.util.hash.FNV1 |
---|
init, init, update, update |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public FNV132()
Method Detail |
---|
public long getHash()
FNV1
getHash
in class FNV1
protected long fnv(byte[] buf, int offset, int len, long seed)
FNV1
fnv
in class FNV1
buf
- byte buffer from which to compute the hashoffset
- starting position in the bufferlen
- number of bytes after the starting positionseed
- initial seed (or previous hash value)
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |