public class MetroHash128 extends AbstractMetroHash<MetroHash128> implements Hash128<byte[]>
官方实现:https://github.com/jandrewrogers/MetroHash 官方文档:http://www.jandrewrogers.com/2015/05/27/metrohash/ 来自:https://github.com/postamar/java-metrohash/
Constructor and Description |
---|
MetroHash128(long seed)
使用指定种子构造
|
Modifier and Type | Method and Description |
---|---|
Number128 |
get()
获取结果hash值
|
Number128 |
hash128(byte[] bytes)
计算Hash值
|
static MetroHash128 |
of(long seed)
创建
MetroHash128 对象 |
MetroHash128 |
reset()
重置,重置后可复用对象开启新的计算
|
MetroHash128 |
write(ByteBuffer output,
ByteOrder byteOrder)
将结果hash值写出到
ByteBuffer 中,可选端序 |
apply
public static MetroHash128 of(long seed)
MetroHash128
对象seed
- 种子MetroHash128
对象public MetroHash128 reset()
MetroHash
reset
in interface MetroHash<MetroHash128>
public Number128 get()
public MetroHash128 write(ByteBuffer output, ByteOrder byteOrder)
MetroHash
ByteBuffer
中,可选端序write
in interface MetroHash<MetroHash128>
output
- 输出byteOrder
- 端序Copyright © 2025. All rights reserved.