ligo/src/proto/alpha/level_repr.mli

34 lines
1.2 KiB
OCaml
Raw Normal View History

2016-09-08 21:13:10 +04:00
(**************************************************************************)
(* *)
(* Copyright (c) 2014 - 2016. *)
(* Dynamic Ledger Solutions, Inc. <contact@tezos.com> *)
(* *)
(* All rights reserved. No warranty, explicit or implicit, provided. *)
(* *)
(**************************************************************************)
type t = private {
level: Raw_level_repr.t ;
level_position: int32 ;
2016-09-08 21:13:10 +04:00
cycle: Cycle_repr.t ;
cycle_position: int32 ;
voting_period: Voting_period_repr.t ;
voting_period_position: int32 ;
}
type level = t
val encoding: level Data_encoding.t
val pp: Format.formatter -> level -> unit
val pp_full: Format.formatter -> level -> unit
2016-09-08 21:13:10 +04:00
include Compare.S with type t := level
val root: Raw_level_repr.t -> level
2016-09-08 21:13:10 +04:00
val from_raw:
first_level:Raw_level_repr.t ->
cycle_length:int32 ->
voting_period_length:int32 ->
2016-09-08 21:13:10 +04:00
Raw_level_repr.t -> level
val diff: level -> level -> int32