Details
A hash function maps arbitrary data to fixed-size integers, called hashes. You feed data to a Hasher by calling its combine methods and then call finalize to compute a hash.
Members
Functions
fun finalize() -> Int { sink }
Returns the hash value computed by self.
fun combine(byte: Int8) { inout }
Adds byte to the hash value computed by self.
fun combine(i32: Int32) { inout }
Adds i32 to the hash value computed by self.
fun combine(i64: Int64) { inout }
Adds i64 to the hash value computed by self.
fun unsafe_combine(bytes: PointerToBuffer<Int8>) { inout }
Adds bytes to the hash value computed by self.
fun combine<T: Hashable>(_ value: T) { inout }
Adds value to the hash value computed by self.
Initializers
init()
Creates a new instance.