Example #1
0
 public override int GetHashCode()
 {
     fixed(byte *pbyte = bytes)
     {
         return((int)Hasher32.ComputeKey(pbyte, 8));
     }
 }
 /// <summary>
 /// The ComputeKey.
 /// </summary>
 /// <param name="bytes">The bytes<see cref="byte[]"/>.</param>
 /// <param name="seed">The seed<see cref="ulong"/>.</param>
 /// <returns>The <see cref="UInt64"/>.</returns>
 public override unsafe UInt64 ComputeKey(byte[] bytes, ulong seed = 0)
 {
     return(Hasher32.ComputeKey(bytes, seed));
 }
 /// <summary>
 /// The ComputeKey.
 /// </summary>
 /// <param name="bytes">The bytes<see cref="byte*"/>.</param>
 /// <param name="length">The length<see cref="int"/>.</param>
 /// <param name="seed">The seed<see cref="ulong"/>.</param>
 /// <returns>The <see cref="UInt64"/>.</returns>
 public override unsafe UInt64 ComputeKey(byte *bytes, int length, ulong seed = 0)
 {
     return(Hasher32.ComputeKey(bytes, length, seed));
 }
 /// <summary>
 /// The ComputeBytes.
 /// </summary>
 /// <param name="bytes">The bytes<see cref="byte[]"/>.</param>
 /// <param name="seed">The seed<see cref="ulong"/>.</param>
 /// <returns>The <see cref="Byte[]"/>.</returns>
 public override unsafe Byte[] ComputeBytes(byte[] bytes, ulong seed = 0)
 {
     return(Hasher32.ComputeBytes(bytes, seed));
 }
 /// <summary>
 /// The ComputeBytes.
 /// </summary>
 /// <param name="bytes">The bytes<see cref="byte*"/>.</param>
 /// <param name="length">The length<see cref="int"/>.</param>
 /// <param name="seed">The seed<see cref="ulong"/>.</param>
 /// <returns>The <see cref="Byte[]"/>.</returns>
 public override unsafe Byte[] ComputeBytes(byte *bytes, int length, ulong seed = 0)
 {
     return(Hasher32.ComputeBytes(bytes, length, seed));
 }