|
|
@@ -13,3 +13,20 @@
|
|
|
│
|
|
|
└─ strategy // 策略层(主逻辑、风控等)
|
|
|
```
|
|
|
+
|
|
|
+```
|
|
|
+币安深度示例-
|
|
|
+ //币安---深度socket-公共频道订阅
|
|
|
+ let get_res_data = move |res_data: ResponseData| {
|
|
|
+ async move {
|
|
|
+ println!("?????{:?}", res_data);
|
|
|
+ }
|
|
|
+ };
|
|
|
+
|
|
|
+
|
|
|
+ let mut btree_map: BTreeMap<String, String> = BTreeMap::new();
|
|
|
+ btree_map.insert("lable".parse().unwrap(), "binance".parse().unwrap());//交易行名称
|
|
|
+
|
|
|
+ let ba_exc = BinanceUsdtSwapWs::new(false, true, btree_map);
|
|
|
+ ba_exc.kline(vec![&"BTCUSDT"], get_res_data);
|
|
|
+```
|