Tsify Process
This commit is contained in:
parent
541ad36d13
commit
2c5ed2c94a
@ -14,7 +14,8 @@ use crate::{
|
|||||||
MutexExt,
|
MutexExt,
|
||||||
};
|
};
|
||||||
|
|
||||||
#[derive(Debug, Clone, Default, PartialEq, Serialize, Deserialize)]
|
#[derive(Debug, Clone, Default, PartialEq, Serialize, Deserialize, Tsify)]
|
||||||
|
#[tsify(into_wasm_abi)]
|
||||||
pub struct ProcessState {
|
pub struct ProcessState {
|
||||||
pub commited_in: OutPoint,
|
pub commited_in: OutPoint,
|
||||||
pub pcd_commitment: Value, // If we can't modify a field, we just copy the previous value
|
pub pcd_commitment: Value, // If we can't modify a field, we just copy the previous value
|
||||||
@ -169,7 +170,8 @@ impl ProcessState {
|
|||||||
/// A process is basically a succession of states
|
/// A process is basically a succession of states
|
||||||
/// If a process has nothing to do with us, impending_requests will be empty
|
/// If a process has nothing to do with us, impending_requests will be empty
|
||||||
/// The latest state MUST be an empty state with only the commited_in field set at the last unspent outpoint
|
/// The latest state MUST be an empty state with only the commited_in field set at the last unspent outpoint
|
||||||
#[derive(Debug, Default, Clone, PartialEq, Serialize, Deserialize)]
|
#[derive(Debug, Default, Clone, PartialEq, Serialize, Deserialize, Tsify)]
|
||||||
|
#[tsify(into_wasm_abi)]
|
||||||
pub struct Process {
|
pub struct Process {
|
||||||
states: Vec<ProcessState>,
|
states: Vec<ProcessState>,
|
||||||
impending_requests: Vec<Prd>,
|
impending_requests: Vec<Prd>,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user