package tezos-protocol-alpha

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module Tezos_raw_protocol_alpha.Sc_rollup_reveal_hashSource

Sourcetype t

The type of a reveal hash.

Sourcetype supported_hashes =
  1. | Blake2B

The hashing schemes supported by the reveal hash.

A Map module for storing reveal-hash-indexed values.

Sourceval size : scheme:supported_hashes -> int

size ~scheme returns the size of reveal hashes using the scheme specified in input.

Sourceval zero : scheme:supported_hashes -> t

zero ~scheme returns the reveal hash corresponding to the zero hash for the scheme specified in input.

Formatting function for reveal-hashes.

Sourceval equal : t -> t -> bool

equal hash1 hash2 checks if the two reveal-hashes hash1 and hash2 are equal. This function must preserve the equality of individual supported hashing schemes. If hash1 and hash2 are hashes obtained from the same supported hashing scheme, then the equal function from that hashing scheme is used to determine whether they are equivalent. Otherwise, they are different.

Sourceval compare : t -> t -> int

compare hash1 hash2 compares the values of the reveal hashes hash1 and hash2. This function must preserve the ordering of individual supported hashing scheme. If hash1 and hash2 are reveal-hashes obtained from the same hashing scheme, then compare hash1 hash2 should return the same result of the compare function exposed by the hash module corresponding to their hashing scheme.

The encoding of reveal hashes.

Sourceval hash_string : scheme:supported_hashes -> ?key:string -> string list -> t

hash_string ~scheme ?key strings hashes strings using the supported hashing scheme given in input.

Sourceval hash_bytes : scheme:supported_hashes -> ?key:bytes -> bytes list -> t

hash_bytes ~scheme ?key strings hashes bytes using the supported hashing scheme given in input.

Sourceval scheme_of_hash : t -> supported_hashes

scheme_of_hash hash returns the supported hashing scheme that was used to obtain hash.

Sourceval of_hex : string -> t option
Sourceval to_hex : t -> string
OCaml

Innovation. Community. Security.