Open 7jrxt42BxFZo4iAnN4CX opened 2 months ago
Fix "MSK" time zone. Fix Reader.run() to receive large messages. Before this, the message(scanner_parameters) was split into three messages.
Scanner parameters: req_scanner_parameters() decode scanner_parameters parsing xml creating input data for macros created macros for selecting from the desired options on ScannerSubscription. Scanner subscriptions: ScannerSubscription builder req_scanner_subscription() decode scanner_data
Scanner parameters:
Scanner subscriptions:
Refused scannerSubscriptionOptions and scannerSubscriptionFilterOptions, leaving only the ScannerSubscription builder (Instrument -> location -> ScanCode -> Filters).
/// # Example /// /// let scanner_wo_filters = ScannerSubscription::us_stocks().us_major().top_perc_gain(); /// let scanner_w_filters = scanner_wo_filters.clone().market_cap_above1e6(1000.0).price_below(100.0); /// /// client.req_scanner_subscription(scanner_w_filters).await;
I decode the contract from scanner_data_msg and create the structure:
pub struct ScannerContract { pub result_number: i32, // remove? pub contract_id: ContractId, pub symbol: String, pub sec_type: ContractType, pub expiration_date: String, pub strike: String, pub class: String, // right pub exchange: Routing, pub currency: Currency, pub local_symbol: String, pub market_name: String, pub trading_class: String, pub distance: String, pub benchmark: String, pub projection: String, pub legs_str: String, }
Question: should we create another structure, like Contract(enum)? p.s There is also a scanner for native combos (with legs).
Limiters: In progress..
Will try to merge this soon
It works. You can merge.
Fix "MSK" time zone. Fix Reader.run() to receive large messages. Before this, the message(scanner_parameters) was split into three messages.
Refused scannerSubscriptionOptions and scannerSubscriptionFilterOptions, leaving only the ScannerSubscription builder (Instrument -> location -> ScanCode -> Filters).
I decode the contract from scanner_data_msg and create the structure:
Question: should we create another structure, like Contract(enum)? p.s There is also a scanner for native combos (with legs).