Function split_symbol
Source pub fn split_symbol(symbol: &str) -> (&str, &str)
Expand description
将合约代码拆分为交易所和合约
symbol - 合约代码(格式:EXCHANGE.INSTRUMENT)
(exchange, instrument) 元组
let (exchange, instrument) = split_symbol("SHFE.au2602");
assert_eq!(exchange, "SHFE");
assert_eq!(instrument, "au2602");