package octez-shell-libs
Install
Dune Dependency
Authors
Maintainers
Sources
sha256=aa2f5bc99cc4ca2217c52a1af2a2cdfd3b383208cb859ca2e79ca0903396ca1d
sha512=d68bb3eb615e3dcccc845fddfc9901c95b3c6dc8e105e39522ce97637b1308a7fa7aa1d271351d5933febd7476b2819e1694f31198f1f0919681f1f9cc97cb3a
doc/octez-shell-libs.shell/Tezos_shell/Shell_operation/index.html
Module Tezos_shell.Shell_operation
Source
This module provides the operation representation used by the prevalidator and its dependencies. It also contains tools for parsing an operation into this representation, and updating the latter.
type 'protocol_operation operation = private {
hash : Tezos_base.TzPervasives.Operation_hash.t;
(*Hash of an operation.
*)raw : Tezos_base.Operation.t;
(*Raw representation of an operation (from the point view of the shell).
*)protocol : 'protocol_operation;
(*Economic protocol specific data of an operation. It is the unserialized representation of
*)raw.protocol_data
. For convenience, the type associated to this type may beunit
if we do not have deserialized the operation yet.signature_checked : bool;
(*This field is initially
*)false
. It is set totrue
when the operation is successfully validated in any context. While this does not guarantee that the operation will still be valid in another validation context, it notably means that the signature is correct. Therefore, when this field istrue
, we can tell the protocol to skip signature checks.size : int;
(*Size of the operation in bytes.
*)
}
Representation of a parsed operation, used only in the shell.
val record_successful_signature_check :
'protocol_operation operation ->
'protocol_operation operation
Return the operation with the signature_checked
field set to true
.
The purpose of this module type is to provide the parse
function, whose return type depends on the protocol.
module MakeParser
(Proto : Tezos_protocol_environment.PROTOCOL) :
PARSER with type protocol_operation = Proto.operation
Create a PARSER
tailored to a given protocol.