Class XXHash

    • Method Detail

      • newXXHash64

        public static XXHash newXXHash64​(long seed)
        Create new streaming XXHash64.
        Parameters:
        seed - seed to use for the hash
        Returns:
        new XXHash instance
      • newXXHash64

        public static XXHash newXXHash64()
        Create new streaming XXHash64.
        Returns:
        new XXHash instance
      • newXXHash3_64

        public static XXHash newXXHash3_64​(long seed)
        Create new streaming XXHash3_64.
        Parameters:
        seed - seed to use for the hash
        Returns:
        new XXHash instance
      • newXXHash3_64

        public static XXHash newXXHash3_64()
        Create new streaming XXHash3_64.
        Returns:
        new XXHash instance
      • newXXHash3_128

        public static XXHash newXXHash3_128​(long seed)
        Create new streaming XXHash3_128.
        Parameters:
        seed - seed to use for the hash
        Returns:
        new XXHash instance
      • newXXHash3_128

        public static XXHash newXXHash3_128()
        Create new streaming XXHash3_128.
        Returns:
        new XXHash instance
      • update

        public void update​(byte[] input)
        Update xxhash state from input
        Parameters:
        input - input to update with
      • update

        public void update​(int b)
        Update xxhash state with a single byte
        Parameters:
        b - input to update with
      • update

        public void update​(byte[] input,
                           int offset,
                           int length)
        Update xxhash state with a subrange of input
        Parameters:
        input - input to update with
        offset - to start update with
        length - of data
      • digest

        public byte[] digest()
        Return digest for the current state of hash.
        Returns:
        hash as bytes in big endian
      • computeXXHash64

        public static byte[] computeXXHash64​(byte[] input,
                                             long seed)
        Oneshot compute XXHash64.
        Parameters:
        input - input input to hash
        seed - seed
        Returns:
        xxhash64 hash
      • computeXXHash64

        public static byte[] computeXXHash64​(byte[] input)
        Oneshot compute XXHash64.
        Parameters:
        input - input input to hash
        Returns:
        xxhash64 hash
      • computeXXHash3_64

        public static byte[] computeXXHash3_64​(byte[] input,
                                               long seed)
        Oneshot compute XXHash3_64.
        Parameters:
        input - input input to hash
        seed - seed
        Returns:
        xxhash64 hash
      • computeXXHash3_64

        public static byte[] computeXXHash3_64​(byte[] input)
        Oneshot compute XXHash3_64.
        Parameters:
        input - input input to hash
        Returns:
        xxhash64 hash
      • computeXXHash3_128

        public static byte[] computeXXHash3_128​(byte[] input,
                                                long seed)
        Oneshot compute XXHash3_128.
        Parameters:
        input - input input to hash
        seed - seed
        Returns:
        xxhash64 hash
      • computeXXHash3_128

        public static byte[] computeXXHash3_128​(byte[] input)
        Oneshot compute XXHash3_128.
        Parameters:
        input - input input to hash
        Returns:
        xxhash64 hash