@@ -2,11 +2,99 @@ syntax = "proto3";
2
2
package tendermint.liquidity ;
3
3
4
4
import "liquidity.proto" ;
5
+ import "tx.proto" ;
5
6
import "gogoproto/gogo.proto" ;
7
+ import "cosmos_proto/coin.proto" ;
6
8
7
9
option go_package = "github.com/tendermint/liquidity/types" ;
8
10
9
- // GenesisState defines the nft module's genesis state.
11
+
12
+ message LiquidityPoolRecord {
13
+ LiquidityPool liquidity_pool = 1 [(gogoproto.nullable ) = false , (gogoproto.moretags ) = "yaml:\"liquidity_pool\"" ];
14
+ LiquidityPoolMetaData liquidity_pool_meta_data = 2 [(gogoproto.nullable ) = false , (gogoproto.moretags ) = "yaml:\"liquidity_pool_meta_data\"" ];
15
+ LiquidityPoolBatch liquidity_pool_batch = 3 [(gogoproto.nullable ) = false , (gogoproto.moretags ) = "yaml:\"liquidity_pool_batch\"" ];
16
+ // TODO: msg in BatchPool*Msg pointer issue, try and delete when unnecessary
17
+ repeated BatchPoolSwapMsgRecord batch_pool_swap_msg_records = 4 [(gogoproto.nullable ) = false , (gogoproto.moretags ) = "yaml:\"batch_pool_swap_msg_records\"" ];
18
+ repeated BatchPoolDepositMsg batch_pool_deposit_msgs = 5 [(gogoproto.nullable ) = false , (gogoproto.moretags ) = "yaml:\"batch_pool_deposit_msgs\"" ];
19
+ repeated BatchPoolWithdrawMsg batch_pool_withdraw_msgs = 6 [(gogoproto.nullable ) = false , (gogoproto.moretags ) = "yaml:\"batch_pool_withdraw_msgs\"" ];
20
+ repeated BatchPoolSwapMsg batch_pool_swap_msgs = 7 [(gogoproto.nullable ) = false , (gogoproto.moretags ) = "yaml:\"batch_pool_swap_msgs\"" ];
21
+ // TODO: invariant check balance of escrow module acc, reserveAcc
22
+ }
23
+
24
+
25
+ // GenesisState defines the liquidity module's genesis state.
10
26
message GenesisState {
27
+ option (gogoproto.equal ) = false ;
28
+ option (gogoproto.goproto_getters ) = false ;
29
+
30
+ // params defines all the parameters of related to liquidity.
11
31
Params params = 1 [(gogoproto.nullable ) = false ];
32
+
33
+
34
+ repeated LiquidityPoolRecord liquidity_pool_records = 2 [(gogoproto.nullable ) = false , (gogoproto.moretags ) = "yaml:\"liquidity_pools\"" ];
35
+ }
36
+
37
+ //
38
+ //// GenesisState defines the liquidity module's genesis state.
39
+ //message GenesisState {
40
+ // option (gogoproto.equal) = false;
41
+ // option (gogoproto.goproto_getters) = false;
42
+ //
43
+ // // params defines all the parameters of related to liquidity.
44
+ // Params params = 1 [(gogoproto.nullable) = false];
45
+ //
46
+ // repeated LiquidityPool liquidity_pools = 2 [(gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"liquidity_pools\""];
47
+ //
48
+ // repeated LiquidityPoolMetaData liquidity_pools_meta_data = 3 [(gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"liquidity_pools_meta_data\""];
49
+ //
50
+ // repeated LiquidityPoolBatch liquidity_pool_batches = 4 [(gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"liquidity_pool_batches\""];
51
+ //
52
+ // repeated BatchPoolDepositMsg batch_pool_deposit_msgs = 5 [(gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"batch_pool_deposit_msgs\""];
53
+ //
54
+ // repeated BatchPoolWithdrawMsg batch_pool_withdraw_msgs = 6 [(gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"batch_pool_withdraw_msgs\""];
55
+ //
56
+ // repeated BatchPoolSwapMsg batch_pool_swap_msgs = 7 [(gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"batch_pool_swap_msgs\""];
57
+ //
58
+ // repeated BatchPoolSwapMsgRecord batch_pool_swap_msg_records = 8 [(gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"batch_pool_swap_msg_records\""];
59
+ //
60
+ // repeated QueryLiquidityPoolResponse liquidity_pool_records = 9 [(gogoproto.nullable) = false, (gogoproto.moretags) = "yaml:\"liquidity_pool_records\""];
61
+ //
62
+ // // TODO: invariant check balance of escrow module acc, reserveAcc
63
+ //
64
+ //}
65
+ //
66
+ //message BatchPoolDepositMsgRecord {
67
+ // int64 msg_height = 1 [(gogoproto.moretags) = "yaml:\"msg_height\""];
68
+ // uint64 msg_index = 2 [(gogoproto.moretags) = "yaml:\"msg_index\""];
69
+ // bool executed = 3 [(gogoproto.moretags) = "yaml:\"executed\""];
70
+ // bool succeed = 4 [(gogoproto.moretags) = "yaml:\"succeed\""];
71
+ // bool to_delete = 5 [(gogoproto.moretags) = "yaml:\"to_delete\""];
72
+ // MsgDepositToLiquidityPool Msg = 6 [(gogoproto.moretags) = "yaml:\"msg\"", (gogoproto.nullable) = false];
73
+ //}
74
+ //
75
+ //message BatchPoolWithdrawMsgRecord {
76
+ // int64 msg_height = 1 [(gogoproto.moretags) = "yaml:\"msg_height\""];
77
+ // uint64 msg_index = 2 [(gogoproto.moretags) = "yaml:\"msg_index\""];
78
+ // bool executed = 3 [(gogoproto.moretags) = "yaml:\"executed\""];
79
+ // bool succeed = 4 [(gogoproto.moretags) = "yaml:\"succeed\""];
80
+ // bool to_delete = 5 [(gogoproto.moretags) = "yaml:\"to_delete\""];
81
+ // MsgWithdrawFromLiquidityPool msg = 6 [(gogoproto.moretags) = "yaml:\"msg\"", (gogoproto.nullable) = false];
82
+ //}
83
+ //
84
+ message BatchPoolSwapMsgRecord {
85
+ int64 msg_height = 1 [(gogoproto.moretags ) = "yaml:\"msg_height\"" ];
86
+ uint64 msg_index = 2 [(gogoproto.moretags ) = "yaml:\"msg_index\"" ];
87
+ bool executed = 3 [(gogoproto.moretags ) = "yaml:\"executed\"" ];
88
+ bool succeed = 4 [(gogoproto.moretags ) = "yaml:\"succeed\"" ];
89
+ bool to_delete = 5 [(gogoproto.moretags ) = "yaml:\"to_delete\"" ];
90
+ int64 order_expiry_height = 6 [(gogoproto.moretags ) = "yaml:\"order_expiry_height\"" ];
91
+ cosmos.base.v1beta1.Coin exchanged_offer_coin = 7 [
92
+ (gogoproto.nullable ) = false ,
93
+ (gogoproto.moretags ) = "yaml:\"exchanged_offer_coin\""
94
+ ];
95
+ cosmos.base.v1beta1.Coin remaining_offer_coin = 8 [
96
+ (gogoproto.nullable ) = false ,
97
+ (gogoproto.moretags ) = "yaml:\"remaining_offer_coin\""
98
+ ];
99
+ MsgSwap msg = 9 [(gogoproto.moretags ) = "yaml:\"msg\"" , (gogoproto.nullable ) = false ];
12
100
}
0 commit comments