Mavryk_client_001_PtAtLas.Annotated_manager_operation
Annotated manager operations are wrappers used to accumulate information (especially about limits) on the operation prior to the injection.
type _ t =
| Manager_info : {
source : Mavryk_protocol_001_PtAtLas.Protocol.Alpha_context.public_key_hash
option;
fee : Mavryk_protocol_001_PtAtLas.Protocol.Alpha_context.Tez.t Limit.t;
gas_limit : Mavryk_protocol_001_PtAtLas.Protocol.Alpha_context.Gas.Arith.integral
Limit.t;
storage_limit : Z.t Limit.t;
counter : Mavryk_protocol_001_PtAtLas.Protocol.Alpha_context.Manager_counter.t
option;
operation : 'kind
Mavryk_protocol_001_PtAtLas.Protocol.Alpha_context.manager_operation;
} -> 'kind t
type _ annotated_list =
| Single_manager : 'kind t -> 'kind annotated_list
| Cons_manager : 'kind t * 'rest annotated_list -> ('kind * 'rest) annotated_list
The annotated_list
type helps making contents_list
from a list of manager_operation
s. Its construction mimics contents_list
in order to keep consistent types when calling inject_manager_operation
and inject_operation
.
val manager_to_list : packed_annotated_list -> packed list
Convert a list of annotated operations to a list of packed annotated operations
val manager_of_list : packed list -> packed_annotated_list
Converse of manager_to_list
val join_fee :
Mavryk_protocol_001_PtAtLas.Protocol.Alpha_context.Tez.t Limit.t ->
'a t ->
'a t Mavryk_base.TzPervasives.tzresult
join_fee fee op
updates op.fee
to Limit.join op.fee fee
and fails if the join fails
val set_fee :
Mavryk_protocol_001_PtAtLas.Protocol.Alpha_context.Tez.t Limit.t ->
'a t ->
'a t
set_fee fee op
updates op.fee
to fee
val join_gas_limit :
Mavryk_protocol_001_PtAtLas.Protocol.Alpha_context.Gas.Arith.integral Limit.t ->
'a t ->
'a t Mavryk_base.TzPervasives.tzresult
See join_fee
val set_gas_limit :
Mavryk_protocol_001_PtAtLas.Protocol.Alpha_context.Gas.Arith.integral Limit.t ->
'a t ->
'a t
See set_fee
val join_storage_limit :
Z.t Limit.t ->
'a t ->
'a t Mavryk_base.TzPervasives.tzresult
See join_fee
val set_counter :
Mavryk_protocol_001_PtAtLas.Protocol.Alpha_context.Manager_counter.t ->
'a t ->
'a t Mavryk_base.TzPervasives.tzresult
Set the counter of the annotated operation. Fail if the counter is already set.
val set_source :
Mavryk_protocol_001_PtAtLas.Protocol.Alpha_context.public_key_hash ->
'a t ->
'a t Mavryk_base.TzPervasives.tzresult
Set the source of the operation. Fail if the source is already set.
val manager_from_annotated :
'a t ->
'a Mavryk_protocol_001_PtAtLas.Protocol.Alpha_context.Kind.manager
Mavryk_protocol_001_PtAtLas.Protocol.Alpha_context.contents
Mavryk_base.TzPervasives.tzresult
Convert an annotated manager operation to a proper manager operation. Fail if some fields in the annotated operation are not set.
val manager_list_from_annotated :
'kind annotated_list ->
'kind Mavryk_protocol_001_PtAtLas.Protocol.Alpha_context.Kind.manager
Mavryk_protocol_001_PtAtLas.Protocol.Alpha_context.contents_list
Mavryk_base.TzPervasives.tzresult