1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
// use binary_options_tools_macros::ActionImpl;
// // Define the ActionName trait (you'll need to import this in real usage)
// trait ActionName {
// fn name(&self) -> &str;
// }
// // Example usage of the ActionImpl derive macro
// #[derive(ActionImpl)]
// #[action(name = "login")]
// struct LoginAction {
// username: String,
// password: String,
// }
// #[derive(ActionImpl)]
// #[action(name = "trade")]
// struct TradeAction {
// asset: String,
// amount: f64,
// direction: String,
// }
// #[derive(ActionImpl)]
// #[action(name = "get_balance")]
// enum BalanceAction {
// Real,
// Demo,
// }