File tree Expand file tree Collapse file tree 2 files changed +43
-0
lines changed Expand file tree Collapse file tree 2 files changed +43
-0
lines changed Original file line number Diff line number Diff line change @@ -17,6 +17,8 @@ pub mod merkle_tree;
17
17
pub mod sentry;
18
18
pub mod targeting;
19
19
pub mod targeting_tag;
20
+ pub mod supermarket;
21
+
20
22
pub mod util {
21
23
pub mod tests {
22
24
pub mod prep_db;
Original file line number Diff line number Diff line change
1
+ use crate :: { BalancesMap , Channel } ;
2
+
3
+ #[ derive( Debug , Clone ) ]
4
+ pub struct Campaign {
5
+ channel : Channel ,
6
+ status : Status ,
7
+ balances : BalancesMap ,
8
+ }
9
+
10
+ impl Campaign {
11
+ pub fn new ( channel : Channel , status : Status , balances : BalancesMap ) -> Self {
12
+ Self {
13
+ channel,
14
+ status,
15
+ balances,
16
+ }
17
+ }
18
+ }
19
+
20
+ #[ derive( Debug , Eq , PartialEq , Clone ) ]
21
+ pub enum Status {
22
+ // Active and Ready
23
+ Active ,
24
+ Pending ,
25
+ Initializing ,
26
+ Waiting ,
27
+ Finalized ( Finalized ) ,
28
+ Unsound {
29
+ disconnected : bool ,
30
+ offline : bool ,
31
+ rejected_state : bool ,
32
+ unhealthy : bool ,
33
+ } ,
34
+ }
35
+
36
+ #[ derive( Debug , PartialEq , Eq , Clone ) ]
37
+ pub enum Finalized {
38
+ Expired ,
39
+ Exhausted ,
40
+ Withdraw ,
41
+ }
You can’t perform that action at this time.
0 commit comments