Library
Module
Module type
Parameter
Class
Class type
type chain_prefix = unit * chain
val chain_path : (unit, chain_prefix) Tezos_rpc.RPC_path.t
val chain_to_string : chain -> string
val chain_arg : chain Tezos_rpc.RPC_arg.t
type block = [
|
`Genesis
(*The genesis block
*)|
`Head of int
(*The
*)n
th predecessor of thecurrent_head
block ifn > 0
. Ifn = 0
, represents thecurrent_head
.n
should not be negative since thecurrent_head
does not have successors.|
`Alias of [ `Caboose | `Checkpoint | `Savepoint ] * int
(*The
*)n
th predecessor of thecaboose
, thecheckpoint
or thesavepoint
ifn > 0
. Ifn = 0
, represents the block itself. Ifn < 0
, represents then
th successor.|
`Hash of Tezos_crypto.Block_hash.t * int
(*The
*)n
th predecessor of the block of givenhash
ifn > 0
. Ifn = 0
, represents the block itself. Otherwise, ifn < 0
, represents then
th successor.|
`Level of Int32.t
(*The block at a given
*)level
]
A representation of a block's position relatively to a known block of a chain.
val to_string : block -> string
val dir_path : (chain_prefix, chain_prefix) Tezos_rpc.RPC_path.t
val path : (chain_prefix, chain_prefix * block) Tezos_rpc.RPC_path.t
val mempool_path :
('a, 'b) Tezos_rpc.RPC_path.t ->
('a, 'b) Tezos_rpc.RPC_path.t
val live_blocks_path :
('a, 'b) Tezos_rpc.RPC_path.t ->
('a, 'b) Tezos_rpc.RPC_path.t
type raw_context =
| Key of Bytes.t
(*A leaf, containing a value
*)| Dir of raw_context Tezos_base.TzPervasives.String.Map.t
(*A directory, mapping keys to nested
*)raw_context
s| Cut
(*An omitted piece, because it is too deep compared to the maximum depth requested in the /chains/<chain_id>/blocks/<block_id/context/raw/bytes RPC
*)
The low-level storage exposed as a tree
val raw_context_eq : raw_context -> raw_context -> bool
raw_context_eq rc1 rc2
tests whether rc1
and rc2
are equal, * that is, have the same constructors; and the constructor's content * are recursively equal
val raw_context_encoding : raw_context Tezos_base.TzPervasives.Data_encoding.t
val pp_raw_context : Format.formatter -> raw_context -> unit
val raw_context_insert :
(string list * raw_context) ->
raw_context ->
raw_context
raw_context_insert (k,v) c
inserts a key-value pair (k,v)
in a raw_context c
. If k
collides to a existing sub-tree in c
, the sub-tree is replaced by a new key-value pair.
type merkle_node =
| Hash of merkle_hash_kind * string
(*A shallow node: just a hash
*)| Data of raw_context
(*A full-fledged node containing actual data
*)| Continue of merkle_tree
(*An edge to a more nested tree
*)
A node in a merkle_tree
and merkle_tree = merkle_node Tezos_base.TzPervasives.String.Map.t
The type of Merkle tree used by the light mode
val merkle_tree_eq : merkle_tree -> merkle_tree -> bool
merkle_tree_eq mtree1 mtree2
tests whether mtree1
and mtree2
are equal, * that is, have the same constructors; and the constructor's content * are recursively equal
Whether an RPC caller requests an entirely shallow Merkle tree (Hole
) or whether the returned tree should contain data at the given key (Raw_context
)
val pp_merkle_node : Format.formatter -> merkle_node -> unit
val pp_merkle_tree : Format.formatter -> merkle_tree -> unit
module type PROTO = sig ... end
type protocols = {
current_protocol : Tezos_crypto.Protocol_hash.t;
next_protocol : Tezos_crypto.Protocol_hash.t;
}
val protocols :
Tezos_rpc.RPC_context.simple ->
?chain:chain ->
?block:block ->
unit ->
protocols Tezos_base.TzPervasives.tzresult Lwt.t
module Make (Proto : PROTO) (Next_proto : PROTO) : sig ... end
module Fake_protocol : PROTO
module Empty : sig ... end