pub mod nanobook_broker
pub mod nanobook_broker::binance
pub mod nanobook_broker::binance::audit
pub fn nanobook_broker::binance::audit::check_audit_log_for_sequence(path: &std::path::Path, sequence: u64) -> core::result::Result<bool, std::io::error::Error>
pub fn nanobook_broker::binance::audit::log_idempotency_rejection(path: &std::path::Path, symbol: nanobook::types::Symbol, sequence: u64, client_order_id: &str, reason: &str)
pub fn nanobook_broker::binance::audit::log_order_filled(path: &std::path::Path, order_id: nanobook_broker::OrderId, sequence: u64)
pub fn nanobook_broker::binance::audit::log_order_submitted(path: &std::path::Path, order_id: nanobook_broker::OrderId, symbol: nanobook::types::Symbol, sequence: u64, client_order_id: &str)
pub mod nanobook_broker::binance::auth
pub fn nanobook_broker::binance::auth::sign(query_string: &str, secret_key: &str) -> alloc::string::String
pub mod nanobook_broker::binance::cache
pub struct nanobook_broker::binance::cache::BinanceOrderCache
pub nanobook_broker::binance::cache::BinanceOrderCache::orders: std::collections::hash::map::HashMap<nanobook_broker::OrderId, nanobook_broker::binance::CachedOrder>
impl nanobook_broker::binance::cache::BinanceOrderCache
pub fn nanobook_broker::binance::cache::BinanceOrderCache::load_from_disk(path: &std::path::Path) -> core::result::Result<Self, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::cache::BinanceOrderCache::new() -> Self
pub fn nanobook_broker::binance::cache::BinanceOrderCache::save_to_disk(&self, path: &std::path::Path) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub mod nanobook_broker::binance::client
pub struct nanobook_broker::binance::client::BinanceClient
impl nanobook_broker::binance::client::BinanceClient
pub fn nanobook_broker::binance::client::BinanceClient::account_info(&self) -> core::result::Result<nanobook_broker::binance::types::AccountInfo, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::client::BinanceClient::book_ticker(&self, symbol: &str) -> core::result::Result<nanobook_broker::binance::types::BookTicker, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::client::BinanceClient::cancel_order(&self, symbol: &str, order_id: u64) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::client::BinanceClient::new(api_key: &str, secret_key: &str, testnet: bool) -> Self
pub fn nanobook_broker::binance::client::BinanceClient::order_status(&self, symbol: &str, order_id: u64) -> core::result::Result<nanobook_broker::binance::types::OrderResponse, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::client::BinanceClient::ping(&self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::client::BinanceClient::submit_order(&self, symbol: &str, side: &str, order_type: &str, quantity: &str, price: core::option::Option<&str>, time_in_force: core::option::Option<&str>, client_order_id: core::option::Option<&str>) -> core::result::Result<nanobook_broker::binance::types::OrderResponse, nanobook_broker::error::BrokerError>
impl core::ops::drop::Drop for nanobook_broker::binance::client::BinanceClient
pub fn nanobook_broker::binance::client::BinanceClient::drop(&mut self)
pub mod nanobook_broker::binance::types
pub enum nanobook_broker::binance::types::Discrepancy
pub nanobook_broker::binance::types::Discrepancy::MissingOrder
pub nanobook_broker::binance::types::Discrepancy::MissingOrder::order_id: nanobook_broker::OrderId
pub nanobook_broker::binance::types::Discrepancy::OrderStatusMismatch
pub nanobook_broker::binance::types::Discrepancy::OrderStatusMismatch::broker_status: nanobook_broker::OrderState
pub nanobook_broker::binance::types::Discrepancy::OrderStatusMismatch::local_status: alloc::string::String
pub nanobook_broker::binance::types::Discrepancy::OrderStatusMismatch::order_id: nanobook_broker::OrderId
pub nanobook_broker::binance::types::Discrepancy::OrphanOrder
pub nanobook_broker::binance::types::Discrepancy::OrphanOrder::order_id: nanobook_broker::OrderId
pub nanobook_broker::binance::types::Discrepancy::PositionMismatch
pub nanobook_broker::binance::types::Discrepancy::PositionMismatch::broker_quantity: i64
pub nanobook_broker::binance::types::Discrepancy::PositionMismatch::local_quantity: i64
pub nanobook_broker::binance::types::Discrepancy::PositionMismatch::symbol: nanobook::types::Symbol
pub struct nanobook_broker::binance::types::AccountInfo
pub nanobook_broker::binance::types::AccountInfo::balances: alloc::vec::Vec<nanobook_broker::binance::types::BalanceInfo>
pub nanobook_broker::binance::types::AccountInfo::can_trade: bool
pub nanobook_broker::binance::types::AccountInfo::open_orders: alloc::vec::Vec<nanobook_broker::binance::types::OrderInfo>
pub nanobook_broker::binance::types::AccountInfo::positions: alloc::vec::Vec<nanobook_broker::binance::types::PositionInfo>
pub struct nanobook_broker::binance::types::BalanceInfo
pub nanobook_broker::binance::types::BalanceInfo::asset: alloc::string::String
pub nanobook_broker::binance::types::BalanceInfo::free: alloc::string::String
pub nanobook_broker::binance::types::BalanceInfo::locked: alloc::string::String
pub struct nanobook_broker::binance::types::BookTicker
pub nanobook_broker::binance::types::BookTicker::ask_price: alloc::string::String
pub nanobook_broker::binance::types::BookTicker::ask_qty: alloc::string::String
pub nanobook_broker::binance::types::BookTicker::bid_price: alloc::string::String
pub nanobook_broker::binance::types::BookTicker::bid_qty: alloc::string::String
pub nanobook_broker::binance::types::BookTicker::symbol: alloc::string::String
pub struct nanobook_broker::binance::types::DiscrepancyReport
pub nanobook_broker::binance::types::DiscrepancyReport::discrepancies: alloc::vec::Vec<nanobook_broker::binance::types::Discrepancy>
pub nanobook_broker::binance::types::DiscrepancyReport::has_critical_issues: bool
pub struct nanobook_broker::binance::types::OrderInfo
pub nanobook_broker::binance::types::OrderInfo::executed_qty: alloc::string::String
pub nanobook_broker::binance::types::OrderInfo::order_id: u64
pub nanobook_broker::binance::types::OrderInfo::orig_qty: alloc::string::String
pub nanobook_broker::binance::types::OrderInfo::side: alloc::string::String
pub nanobook_broker::binance::types::OrderInfo::status: alloc::string::String
pub nanobook_broker::binance::types::OrderInfo::symbol: alloc::string::String
pub struct nanobook_broker::binance::types::OrderResponse
pub nanobook_broker::binance::types::OrderResponse::cummulative_quote_qty: alloc::string::String
pub nanobook_broker::binance::types::OrderResponse::executed_qty: alloc::string::String
pub nanobook_broker::binance::types::OrderResponse::order_id: u64
pub nanobook_broker::binance::types::OrderResponse::status: alloc::string::String
pub nanobook_broker::binance::types::OrderResponse::symbol: alloc::string::String
pub struct nanobook_broker::binance::types::PositionInfo
pub nanobook_broker::binance::types::PositionInfo::entry_price: alloc::string::String
pub nanobook_broker::binance::types::PositionInfo::position_amt: alloc::string::String
pub nanobook_broker::binance::types::PositionInfo::symbol: alloc::string::String
pub mod nanobook_broker::binance::websocket
pub enum nanobook_broker::binance::websocket::BinanceWebSocketEvent
pub nanobook_broker::binance::websocket::BinanceWebSocketEvent::AccountUpdate(nanobook_broker::binance::websocket::AccountUpdate)
pub nanobook_broker::binance::websocket::BinanceWebSocketEvent::ExecutionReport(nanobook_broker::binance::websocket::ExecutionReport)
pub nanobook_broker::binance::websocket::BinanceWebSocketEvent::Other(serde_json::value::Value)
pub enum nanobook_broker::binance::websocket::ConnectionState
pub nanobook_broker::binance::websocket::ConnectionState::Connected
pub nanobook_broker::binance::websocket::ConnectionState::Disconnected
pub nanobook_broker::binance::websocket::ConnectionState::Reconnecting
pub struct nanobook_broker::binance::websocket::AccountUpdate
pub nanobook_broker::binance::websocket::AccountUpdate::event_time: core::option::Option<u64>
pub nanobook_broker::binance::websocket::AccountUpdate::raw: serde_json::value::Value
pub struct nanobook_broker::binance::websocket::BinanceWebSocket
impl nanobook_broker::binance::websocket::BinanceWebSocket
pub fn nanobook_broker::binance::websocket::BinanceWebSocket::check_heartbeat(&self) -> bool
pub async fn nanobook_broker::binance::websocket::BinanceWebSocket::connect(&mut self) -> core::result::Result<(), alloc::boxed::Box<dyn core::error::Error>>
pub async fn nanobook_broker::binance::websocket::BinanceWebSocket::disconnect(&mut self)
pub fn nanobook_broker::binance::websocket::BinanceWebSocket::events(&self) -> &[nanobook_broker::binance::websocket::BinanceWebSocketEvent]
pub fn nanobook_broker::binance::websocket::BinanceWebSocket::is_connected(&self) -> bool
pub fn nanobook_broker::binance::websocket::BinanceWebSocket::max_reconnect_attempts(&self) -> u32
pub fn nanobook_broker::binance::websocket::BinanceWebSocket::new(api_key: &str, secret_key: &str, testnet: bool) -> Self
pub fn nanobook_broker::binance::websocket::BinanceWebSocket::reconnect_attempts(&self) -> u32
pub async fn nanobook_broker::binance::websocket::BinanceWebSocket::reconnect_with_backoff(&mut self) -> core::result::Result<(), alloc::boxed::Box<dyn core::error::Error>>
pub async fn nanobook_broker::binance::websocket::BinanceWebSocket::send_ping(&mut self) -> core::result::Result<(), alloc::boxed::Box<dyn core::error::Error>>
pub fn nanobook_broker::binance::websocket::BinanceWebSocket::set_heartbeat_interval(&mut self, interval: core::time::Duration)
pub fn nanobook_broker::binance::websocket::BinanceWebSocket::set_max_reconnect_attempts(&mut self, max: u32)
pub fn nanobook_broker::binance::websocket::BinanceWebSocket::state(&self) -> nanobook_broker::binance::websocket::ConnectionState
pub async fn nanobook_broker::binance::websocket::BinanceWebSocket::subscribe_user_data(&mut self) -> core::result::Result<(), alloc::boxed::Box<dyn core::error::Error>>
pub fn nanobook_broker::binance::websocket::BinanceWebSocket::update_heartbeat(&self)
pub struct nanobook_broker::binance::websocket::ExecutionReport
pub nanobook_broker::binance::websocket::ExecutionReport::client_order_id: core::option::Option<alloc::string::String>
pub nanobook_broker::binance::websocket::ExecutionReport::event_time: core::option::Option<u64>
pub nanobook_broker::binance::websocket::ExecutionReport::order_id: core::option::Option<u64>
pub nanobook_broker::binance::websocket::ExecutionReport::order_status: core::option::Option<alloc::string::String>
pub nanobook_broker::binance::websocket::ExecutionReport::raw: serde_json::value::Value
pub nanobook_broker::binance::websocket::ExecutionReport::symbol: core::option::Option<alloc::string::String>
pub enum nanobook_broker::binance::ConnectionMode
pub nanobook_broker::binance::ConnectionMode::Auto
pub nanobook_broker::binance::ConnectionMode::Rest
pub nanobook_broker::binance::ConnectionMode::WebSocket
pub enum nanobook_broker::binance::Discrepancy
pub nanobook_broker::binance::Discrepancy::MissingOrder
pub nanobook_broker::binance::Discrepancy::MissingOrder::order_id: nanobook_broker::OrderId
pub nanobook_broker::binance::Discrepancy::OrderStatusMismatch
pub nanobook_broker::binance::Discrepancy::OrderStatusMismatch::broker_status: nanobook_broker::OrderState
pub nanobook_broker::binance::Discrepancy::OrderStatusMismatch::local_status: alloc::string::String
pub nanobook_broker::binance::Discrepancy::OrderStatusMismatch::order_id: nanobook_broker::OrderId
pub nanobook_broker::binance::Discrepancy::OrphanOrder
pub nanobook_broker::binance::Discrepancy::OrphanOrder::order_id: nanobook_broker::OrderId
pub nanobook_broker::binance::Discrepancy::PositionMismatch
pub nanobook_broker::binance::Discrepancy::PositionMismatch::broker_quantity: i64
pub nanobook_broker::binance::Discrepancy::PositionMismatch::local_quantity: i64
pub nanobook_broker::binance::Discrepancy::PositionMismatch::symbol: nanobook::types::Symbol
pub struct nanobook_broker::binance::BinanceBroker
impl nanobook_broker::binance::BinanceBroker
pub fn nanobook_broker::binance::BinanceBroker::block_reconciliation(&mut self)
pub fn nanobook_broker::binance::BinanceBroker::cache_order(&self, order_id: nanobook_broker::OrderId, symbol: nanobook::types::Symbol, quantity: i64, side: nanobook_broker::BrokerSide, client_order_id: core::option::Option<alloc::string::String>)
pub fn nanobook_broker::binance::BinanceBroker::cached_positions(&self) -> alloc::vec::Vec<nanobook_broker::Position>
pub fn nanobook_broker::binance::BinanceBroker::check_duplicate_client_order_id(&self, client_order_id: &str) -> bool
pub fn nanobook_broker::binance::BinanceBroker::clear_cache(&self)
pub fn nanobook_broker::binance::BinanceBroker::connection_mode(&self) -> nanobook_broker::binance::ConnectionMode
pub fn nanobook_broker::binance::BinanceBroker::generate_client_order_id(&self, sequence_number: u64) -> alloc::string::String
pub fn nanobook_broker::binance::BinanceBroker::get_cached_order(&self, order_id: nanobook_broker::OrderId) -> core::option::Option<nanobook_broker::binance::CachedOrder>
pub fn nanobook_broker::binance::BinanceBroker::is_reconciliation_blocked(&self) -> bool
pub fn nanobook_broker::binance::BinanceBroker::last_account_poll(&self) -> core::option::Option<std::time::SystemTime>
pub fn nanobook_broker::binance::BinanceBroker::last_orders_poll(&self) -> core::option::Option<std::time::SystemTime>
pub fn nanobook_broker::binance::BinanceBroker::load_cache_from_disk(&self, path: &std::path::Path) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::new(api_key: &str, secret_key: &str, testnet: bool) -> Self
pub fn nanobook_broker::binance::BinanceBroker::poll_account_info(&self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::poll_open_orders(&self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::reconcile_state(&mut self) -> core::result::Result<nanobook_broker::binance::types::DiscrepancyReport, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::save_cache_to_disk(&self, path: &std::path::Path) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::set_last_account_poll(&self, timestamp: core::option::Option<std::time::SystemTime>)
pub fn nanobook_broker::binance::BinanceBroker::set_last_orders_poll(&self, timestamp: core::option::Option<std::time::SystemTime>)
pub fn nanobook_broker::binance::BinanceBroker::should_poll(&self, last_poll: core::option::Option<std::time::SystemTime>) -> bool
pub fn nanobook_broker::binance::BinanceBroker::submit_order_with_sequence(&self, order: &nanobook_broker::BrokerOrder, sequence_number: core::option::Option<u64>) -> core::result::Result<nanobook_broker::OrderId, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::switch_to_rest_mode(&mut self)
pub fn nanobook_broker::binance::BinanceBroker::switch_to_websocket_mode(&mut self)
pub fn nanobook_broker::binance::BinanceBroker::unblock_reconciliation(&mut self)
pub fn nanobook_broker::binance::BinanceBroker::update_cached_order_status(&self, order_id: nanobook_broker::OrderId, status: nanobook_broker::OrderState)
pub fn nanobook_broker::binance::BinanceBroker::update_state_from_account_info(&self, info: &nanobook_broker::binance::types::AccountInfo) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::with_audit_log_path(self, path: std::path::PathBuf) -> Self
pub fn nanobook_broker::binance::BinanceBroker::with_connection_mode(self, mode: nanobook_broker::binance::ConnectionMode) -> Self
pub fn nanobook_broker::binance::BinanceBroker::with_quote_asset(self, quote: &str) -> Self
pub fn nanobook_broker::binance::BinanceBroker::with_sequence_number(self, seq: u64) -> Self
impl core::ops::drop::Drop for nanobook_broker::binance::BinanceBroker
pub fn nanobook_broker::binance::BinanceBroker::drop(&mut self)
impl nanobook_broker::Broker for nanobook_broker::binance::BinanceBroker
pub fn nanobook_broker::binance::BinanceBroker::account(&self) -> core::result::Result<nanobook_broker::Account, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::cancel_order(&self, id: nanobook_broker::OrderId) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::connect(&mut self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::disconnect(&mut self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::open_orders(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::BrokerOrderStatus>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::order_status(&self, id: nanobook_broker::OrderId) -> core::result::Result<nanobook_broker::BrokerOrderStatus, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::positions(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::Position>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::quote(&self, symbol: &nanobook::types::Symbol) -> core::result::Result<nanobook_broker::Quote, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::submit_order(&self, order: &nanobook_broker::BrokerOrder) -> core::result::Result<nanobook_broker::OrderId, nanobook_broker::error::BrokerError>
pub struct nanobook_broker::binance::BinanceOrderCache
pub nanobook_broker::binance::BinanceOrderCache::orders: std::collections::hash::map::HashMap<nanobook_broker::OrderId, nanobook_broker::binance::CachedOrder>
impl nanobook_broker::binance::cache::BinanceOrderCache
pub fn nanobook_broker::binance::cache::BinanceOrderCache::load_from_disk(path: &std::path::Path) -> core::result::Result<Self, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::cache::BinanceOrderCache::new() -> Self
pub fn nanobook_broker::binance::cache::BinanceOrderCache::save_to_disk(&self, path: &std::path::Path) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub struct nanobook_broker::binance::CachedOrder
pub nanobook_broker::binance::CachedOrder::binance_order_id: alloc::string::String
pub nanobook_broker::binance::CachedOrder::client_order_id: core::option::Option<alloc::string::String>
pub nanobook_broker::binance::CachedOrder::quantity: i64
pub nanobook_broker::binance::CachedOrder::side: nanobook_broker::BrokerSide
pub nanobook_broker::binance::CachedOrder::status: nanobook_broker::OrderState
pub nanobook_broker::binance::CachedOrder::submitted_at: chrono::datetime::DateTime<chrono::offset::utc::Utc>
pub nanobook_broker::binance::CachedOrder::symbol: nanobook::types::Symbol
pub struct nanobook_broker::binance::DiscrepancyReport
pub nanobook_broker::binance::DiscrepancyReport::discrepancies: alloc::vec::Vec<nanobook_broker::binance::types::Discrepancy>
pub nanobook_broker::binance::DiscrepancyReport::has_critical_issues: bool
pub fn nanobook_broker::binance::check_audit_log_for_sequence(path: &std::path::Path, sequence: u64) -> core::result::Result<bool, std::io::error::Error>
pub fn nanobook_broker::binance::log_idempotency_rejection(path: &std::path::Path, symbol: nanobook::types::Symbol, sequence: u64, client_order_id: &str, reason: &str)
pub fn nanobook_broker::binance::log_order_submitted(path: &std::path::Path, order_id: nanobook_broker::OrderId, symbol: nanobook::types::Symbol, sequence: u64, client_order_id: &str)
pub mod nanobook_broker::error
pub enum nanobook_broker::error::BrokerError
pub nanobook_broker::error::BrokerError::Auth(alloc::string::String)
pub nanobook_broker::error::BrokerError::CancelReject
pub nanobook_broker::error::BrokerError::CancelReject::order_id: i32
pub nanobook_broker::error::BrokerError::CancelReject::reason: alloc::string::String
pub nanobook_broker::error::BrokerError::Connection(alloc::string::String)
pub nanobook_broker::error::BrokerError::ConnectionLost
pub nanobook_broker::error::BrokerError::ConnectionLost::filled_quantity: i64
pub nanobook_broker::error::BrokerError::ConnectionLost::order_id: i32
pub nanobook_broker::error::BrokerError::DuplicateOrder
pub nanobook_broker::error::BrokerError::DuplicateOrder::client_order_id: alloc::string::String
pub nanobook_broker::error::BrokerError::InvalidSymbol(alloc::string::String)
pub nanobook_broker::error::BrokerError::MarketOrderRejected
pub nanobook_broker::error::BrokerError::NoQuoteForMarketOrder
pub nanobook_broker::error::BrokerError::NoQuoteForMarketOrder::symbol: alloc::string::String
pub nanobook_broker::error::BrokerError::NonFiniteValue
pub nanobook_broker::error::BrokerError::NonFiniteValue::field: &'static str
pub nanobook_broker::error::BrokerError::NonFiniteValue::value: f64
pub nanobook_broker::error::BrokerError::NotConnected
pub nanobook_broker::error::BrokerError::Order(alloc::string::String)
pub nanobook_broker::error::BrokerError::Other(alloc::string::String)
pub nanobook_broker::error::BrokerError::RateLimit
pub nanobook_broker::error::BrokerError::ReconnectFailed
pub nanobook_broker::error::BrokerError::ReconnectFailed::attempts: u32
pub nanobook_broker::error::BrokerError::ReconnectFailed::reason: alloc::string::String
pub nanobook_broker::error::BrokerError::ValueOutOfRange
pub nanobook_broker::error::BrokerError::ValueOutOfRange::field: &'static str
pub nanobook_broker::error::BrokerError::ValueOutOfRange::value: f64
pub mod nanobook_broker::ibkr
pub mod nanobook_broker::ibkr::client
pub struct nanobook_broker::ibkr::client::CachedOrder
pub nanobook_broker::ibkr::client::CachedOrder::order_id: i32
pub nanobook_broker::ibkr::client::CachedOrder::quantity: i64
pub nanobook_broker::ibkr::client::CachedOrder::side: alloc::string::String
pub nanobook_broker::ibkr::client::CachedOrder::status: alloc::string::String
pub nanobook_broker::ibkr::client::CachedOrder::submitted_at: std::time::Instant
pub nanobook_broker::ibkr::client::CachedOrder::symbol: nanobook::types::Symbol
pub struct nanobook_broker::ibkr::client::IbkrClient
impl nanobook_broker::ibkr::client::IbkrClient
pub fn nanobook_broker::ibkr::client::IbkrClient::account_summary(&self) -> core::result::Result<nanobook_broker::Account, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::client::IbkrClient::cache_order(&self, order_id: i32, symbol: nanobook::types::Symbol, quantity: i64, side: alloc::string::String) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::client::IbkrClient::cached_orders(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::ibkr::client::CachedOrder>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::client::IbkrClient::clear_order_cache(&self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::client::IbkrClient::connect(host: &str, port: u16, client_id: i32) -> core::result::Result<Self, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::client::IbkrClient::dedup_cache(&self) -> &std::sync::poison::mutex::Mutex<std::collections::hash::map::HashMap<nanobook_broker::ibkr::client::OrderCallbackKey, std::time::Instant>>
pub fn nanobook_broker::ibkr::client::IbkrClient::get_cached_order(&self, order_id: i32) -> core::result::Result<core::option::Option<nanobook_broker::ibkr::client::CachedOrder>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::client::IbkrClient::inner(&self) -> &ibapi::client::sync::Client
pub fn nanobook_broker::ibkr::client::IbkrClient::is_duplicate_callback(&self, order_id: i32, status: &str, filled_quantity: f64) -> bool
pub fn nanobook_broker::ibkr::client::IbkrClient::mid_price(&self, symbol: &nanobook::types::Symbol) -> core::result::Result<i64, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::client::IbkrClient::open_orders(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::BrokerOrderStatus>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::client::IbkrClient::positions(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::Position>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::client::IbkrClient::prices(&self, symbols: &[nanobook::types::Symbol]) -> core::result::Result<alloc::vec::Vec<(nanobook::types::Symbol, i64)>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::client::IbkrClient::quote(&self, symbol: &nanobook::types::Symbol) -> core::result::Result<nanobook_broker::Quote, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::client::IbkrClient::reconnect(&mut self, host: &str, port: u16, client_id: i32) -> core::result::Result<alloc::vec::Vec<nanobook_broker::Position>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::client::IbkrClient::record_processed_callback(&self, order_id: i32, status: &str, filled_quantity: f64) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::client::IbkrClient::submit_order(&self, order: &nanobook_broker::BrokerOrder) -> core::result::Result<nanobook_broker::OrderId, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::client::IbkrClient::update_cached_order_status(&self, order_id: i32, status: alloc::string::String) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub struct nanobook_broker::ibkr::client::OrderCallbackKey
pub nanobook_broker::ibkr::client::OrderCallbackKey::filled_quantity: i64
pub nanobook_broker::ibkr::client::OrderCallbackKey::order_id: i32
pub nanobook_broker::ibkr::client::OrderCallbackKey::status: alloc::string::String
pub mod nanobook_broker::ibkr::market_data
pub mod nanobook_broker::ibkr::orders
pub enum nanobook_broker::ibkr::orders::OrderOutcome
pub nanobook_broker::ibkr::orders::OrderOutcome::Cancelled
pub nanobook_broker::ibkr::orders::OrderOutcome::Failed
pub nanobook_broker::ibkr::orders::OrderOutcome::Filled
pub nanobook_broker::ibkr::orders::OrderOutcome::PartialFill
pub struct nanobook_broker::ibkr::orders::OrderCallbackKey
pub nanobook_broker::ibkr::orders::OrderCallbackKey::filled_quantity: i64
pub nanobook_broker::ibkr::orders::OrderCallbackKey::order_id: i32
pub nanobook_broker::ibkr::orders::OrderCallbackKey::status: alloc::string::String
pub struct nanobook_broker::ibkr::orders::OrderResult
pub nanobook_broker::ibkr::orders::OrderResult::avg_fill_price: f64
pub nanobook_broker::ibkr::orders::OrderResult::commission: f64
pub nanobook_broker::ibkr::orders::OrderResult::filled_shares: i64
pub nanobook_broker::ibkr::orders::OrderResult::order_id: i32
pub nanobook_broker::ibkr::orders::OrderResult::status: nanobook_broker::ibkr::orders::OrderOutcome
pub nanobook_broker::ibkr::orders::OrderResult::symbol: nanobook::types::Symbol
pub fn nanobook_broker::ibkr::orders::broker_order_status_from_ibkr_parts(order_id: i32, status: &str, filled: f64, remaining: f64, average_fill_price: f64) -> core::result::Result<nanobook_broker::BrokerOrderStatus, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::orders::broker_order_status_from_order_data(order_data: &ibapi::orders::OrderData) -> core::result::Result<nanobook_broker::BrokerOrderStatus, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::orders::cancel_order(client: &ibapi::client::sync::Client, order_id: i32) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::orders::encode_order(order: &nanobook_broker::BrokerOrder, best_quote: core::option::Option<&nanobook_broker::BestQuote>) -> core::result::Result<(f64, f64), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::orders::execute_limit_order(client: &ibapi::client::sync::Client, symbol: nanobook::types::Symbol, side: nanobook_broker::BrokerSide, shares: i64, limit_price_cents: i64, client_order_id: core::option::Option<&nanobook_broker::ClientOrderId>, timeout: core::time::Duration, dedup_cache: core::option::Option<&nanobook_broker::ibkr::orders::CallbackDedupCache>) -> core::result::Result<nanobook_broker::ibkr::orders::OrderResult, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::orders::map_ibkr_order_status(status: &str) -> nanobook_broker::OrderState
pub fn nanobook_broker::ibkr::orders::rate_limit_delay(interval_ms: u64)
pub fn nanobook_broker::ibkr::orders::reconcile_filled_order(order_id: i32, rejection_reason: &str) -> core::result::Result<bool, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::orders::reconcile_partial_fill(order_id: i32, symbol: nanobook::types::Symbol, pre_disconnect_filled: i64, expected_total: i64, current_positions: &[nanobook_broker::Position], side: nanobook_broker::BrokerSide) -> core::result::Result<nanobook_broker::ibkr::orders::OrderResult, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::orders::submit_order(client: &ibapi::client::sync::Client, order: &nanobook_broker::BrokerOrder, best_quote: core::option::Option<&nanobook_broker::BestQuote>) -> core::result::Result<nanobook_broker::OrderId, nanobook_broker::error::BrokerError>
pub type nanobook_broker::ibkr::orders::CallbackDedupCache = std::sync::poison::mutex::Mutex<std::collections::hash::map::HashMap<nanobook_broker::ibkr::orders::OrderCallbackKey, std::time::Instant>>
pub enum nanobook_broker::ibkr::ConnectionState
pub nanobook_broker::ibkr::ConnectionState::Connected
pub nanobook_broker::ibkr::ConnectionState::Disconnected
pub nanobook_broker::ibkr::ConnectionState::Reconnecting
pub enum nanobook_broker::ibkr::Discrepancy
pub nanobook_broker::ibkr::Discrepancy::MissingOrder
pub nanobook_broker::ibkr::Discrepancy::MissingOrder::order_id: nanobook_broker::OrderId
pub nanobook_broker::ibkr::Discrepancy::OrderStatusMismatch
pub nanobook_broker::ibkr::Discrepancy::OrderStatusMismatch::broker_status: nanobook_broker::OrderState
pub nanobook_broker::ibkr::Discrepancy::OrderStatusMismatch::local_status: alloc::string::String
pub nanobook_broker::ibkr::Discrepancy::OrderStatusMismatch::order_id: nanobook_broker::OrderId
pub nanobook_broker::ibkr::Discrepancy::OrphanOrder
pub nanobook_broker::ibkr::Discrepancy::OrphanOrder::order_id: nanobook_broker::OrderId
pub nanobook_broker::ibkr::Discrepancy::PositionMismatch
pub nanobook_broker::ibkr::Discrepancy::PositionMismatch::broker_quantity: i64
pub nanobook_broker::ibkr::Discrepancy::PositionMismatch::local_quantity: i64
pub nanobook_broker::ibkr::Discrepancy::PositionMismatch::symbol: nanobook::types::Symbol
pub struct nanobook_broker::ibkr::DiscrepancyReport
pub nanobook_broker::ibkr::DiscrepancyReport::discrepancies: alloc::vec::Vec<nanobook_broker::ibkr::Discrepancy>
pub nanobook_broker::ibkr::DiscrepancyReport::has_critical_issues: bool
pub struct nanobook_broker::ibkr::IbkrBroker
impl nanobook_broker::ibkr::IbkrBroker
pub fn nanobook_broker::ibkr::IbkrBroker::block_reconciliation(&mut self)
pub fn nanobook_broker::ibkr::IbkrBroker::client(&self) -> core::option::Option<&nanobook_broker::ibkr::client::IbkrClient>
pub fn nanobook_broker::ibkr::IbkrBroker::connection_state(&self) -> nanobook_broker::ibkr::ConnectionState
pub fn nanobook_broker::ibkr::IbkrBroker::is_connected(&self) -> bool
pub fn nanobook_broker::ibkr::IbkrBroker::is_reconciliation_blocked(&self) -> bool
pub fn nanobook_broker::ibkr::IbkrBroker::new(host: &str, port: u16, client_id: i32) -> Self
pub fn nanobook_broker::ibkr::IbkrBroker::reconcile_state(&mut self) -> core::result::Result<nanobook_broker::ibkr::DiscrepancyReport, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::reconnect(&mut self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::Position>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::reconnect_with_backoff(&mut self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::unblock_reconciliation(&mut self)
impl nanobook_broker::Broker for nanobook_broker::ibkr::IbkrBroker
pub fn nanobook_broker::ibkr::IbkrBroker::account(&self) -> core::result::Result<nanobook_broker::Account, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::cancel_order(&self, id: nanobook_broker::OrderId) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::connect(&mut self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::disconnect(&mut self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::open_orders(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::BrokerOrderStatus>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::order_status(&self, id: nanobook_broker::OrderId) -> core::result::Result<nanobook_broker::BrokerOrderStatus, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::positions(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::Position>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::quote(&self, symbol: &nanobook::types::Symbol) -> core::result::Result<nanobook_broker::Quote, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::submit_order(&self, order: &nanobook_broker::BrokerOrder) -> core::result::Result<nanobook_broker::OrderId, nanobook_broker::error::BrokerError>
pub mod nanobook_broker::mock
pub enum nanobook_broker::mock::FillMode
pub nanobook_broker::mock::FillMode::ImmediateFull
pub nanobook_broker::mock::FillMode::ImmediatePartial(f64)
pub nanobook_broker::mock::FillMode::Reject
pub struct nanobook_broker::mock::MockBroker
impl nanobook_broker::mock::MockBroker
pub fn nanobook_broker::mock::MockBroker::builder() -> nanobook_broker::mock::MockBrokerBuilder
pub fn nanobook_broker::mock::MockBroker::submitted_orders(&self) -> alloc::vec::Vec<nanobook_broker::mock::RecordedOrder>
impl nanobook_broker::Broker for nanobook_broker::mock::MockBroker
pub fn nanobook_broker::mock::MockBroker::account(&self) -> core::result::Result<nanobook_broker::Account, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::mock::MockBroker::cancel_order(&self, id: nanobook_broker::OrderId) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::mock::MockBroker::connect(&mut self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::mock::MockBroker::disconnect(&mut self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::mock::MockBroker::open_orders(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::BrokerOrderStatus>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::mock::MockBroker::order_status(&self, id: nanobook_broker::OrderId) -> core::result::Result<nanobook_broker::BrokerOrderStatus, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::mock::MockBroker::positions(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::Position>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::mock::MockBroker::quote(&self, symbol: &nanobook::types::Symbol) -> core::result::Result<nanobook_broker::Quote, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::mock::MockBroker::submit_order(&self, order: &nanobook_broker::BrokerOrder) -> core::result::Result<nanobook_broker::OrderId, nanobook_broker::error::BrokerError>
pub struct nanobook_broker::mock::MockBrokerBuilder
impl nanobook_broker::mock::MockBrokerBuilder
pub fn nanobook_broker::mock::MockBrokerBuilder::build(self) -> nanobook_broker::mock::MockBroker
pub fn nanobook_broker::mock::MockBrokerBuilder::fill_mode(self, mode: nanobook_broker::mock::FillMode) -> Self
pub fn nanobook_broker::mock::MockBrokerBuilder::with_account(self, equity_cents: i64, cash_cents: i64) -> Self
pub fn nanobook_broker::mock::MockBrokerBuilder::with_position(self, symbol: nanobook::types::Symbol, quantity: i64, avg_cost_cents: i64) -> Self
pub fn nanobook_broker::mock::MockBrokerBuilder::with_quote(self, symbol: nanobook::types::Symbol, bid: i64, ask: i64) -> Self
pub struct nanobook_broker::mock::RecordedOrder
pub nanobook_broker::mock::RecordedOrder::client_order_id: core::option::Option<nanobook_broker::ClientOrderId>
pub nanobook_broker::mock::RecordedOrder::order_type: alloc::string::String
pub nanobook_broker::mock::RecordedOrder::quantity: u64
pub nanobook_broker::mock::RecordedOrder::side: nanobook_broker::BrokerSide
pub nanobook_broker::mock::RecordedOrder::symbol: nanobook::types::Symbol
pub mod nanobook_broker::types
pub enum nanobook_broker::types::BrokerOrderType
pub nanobook_broker::types::BrokerOrderType::Limit(nanobook::types::Price)
pub nanobook_broker::types::BrokerOrderType::Market
pub enum nanobook_broker::types::BrokerSide
pub nanobook_broker::types::BrokerSide::Buy
pub nanobook_broker::types::BrokerSide::Sell
pub enum nanobook_broker::types::OrderState
pub nanobook_broker::types::OrderState::Cancelled
pub nanobook_broker::types::OrderState::Filled
pub nanobook_broker::types::OrderState::PartiallyFilled
pub nanobook_broker::types::OrderState::Pending
pub nanobook_broker::types::OrderState::Rejected
pub nanobook_broker::types::OrderState::Submitted
pub struct nanobook_broker::types::Account
pub nanobook_broker::types::Account::buying_power_cents: i64
pub nanobook_broker::types::Account::cash_cents: i64
pub nanobook_broker::types::Account::equity_cents: i64
pub nanobook_broker::types::Account::gross_position_value_cents: i64
pub struct nanobook_broker::types::BestQuote
pub nanobook_broker::types::BestQuote::ask_cents: i64
pub nanobook_broker::types::BestQuote::bid_cents: i64
pub struct nanobook_broker::types::BrokerOrder
pub nanobook_broker::types::BrokerOrder::client_order_id: core::option::Option<nanobook_broker::ClientOrderId>
pub nanobook_broker::types::BrokerOrder::order_type: nanobook_broker::BrokerOrderType
pub nanobook_broker::types::BrokerOrder::quantity: u64
pub nanobook_broker::types::BrokerOrder::side: nanobook_broker::BrokerSide
pub nanobook_broker::types::BrokerOrder::symbol: nanobook::types::Symbol
pub struct nanobook_broker::types::BrokerOrderStatus
pub nanobook_broker::types::BrokerOrderStatus::avg_fill_price_cents: i64
pub nanobook_broker::types::BrokerOrderStatus::filled_quantity: u64
pub nanobook_broker::types::BrokerOrderStatus::id: nanobook_broker::OrderId
pub nanobook_broker::types::BrokerOrderStatus::remaining_quantity: u64
pub nanobook_broker::types::BrokerOrderStatus::status: nanobook_broker::OrderState
pub struct nanobook_broker::types::ClientOrderId(_)
impl nanobook_broker::ClientOrderId
pub fn nanobook_broker::ClientOrderId::as_str(&self) -> &str
pub fn nanobook_broker::ClientOrderId::derive(scope: &str, symbol: &str, side: nanobook_broker::BrokerSide, qty: u64) -> Self
pub fn nanobook_broker::ClientOrderId::new(value: impl core::convert::Into<alloc::string::String>) -> core::result::Result<Self, nanobook_broker::error::BrokerError>
pub struct nanobook_broker::types::OrderId(pub u64)
pub struct nanobook_broker::types::Position
pub nanobook_broker::types::Position::avg_cost_cents: i64
pub nanobook_broker::types::Position::market_value_cents: i64
pub nanobook_broker::types::Position::quantity: i64
pub nanobook_broker::types::Position::symbol: nanobook::types::Symbol
pub nanobook_broker::types::Position::unrealized_pnl_cents: i64
pub struct nanobook_broker::types::Quote
pub nanobook_broker::types::Quote::ask_cents: i64
pub nanobook_broker::types::Quote::bid_cents: i64
pub nanobook_broker::types::Quote::last_cents: i64
pub nanobook_broker::types::Quote::symbol: nanobook::types::Symbol
pub nanobook_broker::types::Quote::timestamp: std::time::SystemTime
pub nanobook_broker::types::Quote::volume: u64
impl nanobook_broker::Quote
pub fn nanobook_broker::Quote::is_stale(&self, threshold_sec: u64) -> bool
pub fn nanobook_broker::types::f64_cents_checked(value: f64, field: &'static str) -> core::result::Result<i64, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::types::f64_to_fixed_checked(value: f64, scale: f64, field: &'static str) -> core::result::Result<i64, nanobook_broker::error::BrokerError>
pub enum nanobook_broker::BrokerError
pub nanobook_broker::BrokerError::Auth(alloc::string::String)
pub nanobook_broker::BrokerError::CancelReject
pub nanobook_broker::BrokerError::CancelReject::order_id: i32
pub nanobook_broker::BrokerError::CancelReject::reason: alloc::string::String
pub nanobook_broker::BrokerError::Connection(alloc::string::String)
pub nanobook_broker::BrokerError::ConnectionLost
pub nanobook_broker::BrokerError::ConnectionLost::filled_quantity: i64
pub nanobook_broker::BrokerError::ConnectionLost::order_id: i32
pub nanobook_broker::BrokerError::DuplicateOrder
pub nanobook_broker::BrokerError::DuplicateOrder::client_order_id: alloc::string::String
pub nanobook_broker::BrokerError::InvalidSymbol(alloc::string::String)
pub nanobook_broker::BrokerError::MarketOrderRejected
pub nanobook_broker::BrokerError::NoQuoteForMarketOrder
pub nanobook_broker::BrokerError::NoQuoteForMarketOrder::symbol: alloc::string::String
pub nanobook_broker::BrokerError::NonFiniteValue
pub nanobook_broker::BrokerError::NonFiniteValue::field: &'static str
pub nanobook_broker::BrokerError::NonFiniteValue::value: f64
pub nanobook_broker::BrokerError::NotConnected
pub nanobook_broker::BrokerError::Order(alloc::string::String)
pub nanobook_broker::BrokerError::Other(alloc::string::String)
pub nanobook_broker::BrokerError::RateLimit
pub nanobook_broker::BrokerError::ReconnectFailed
pub nanobook_broker::BrokerError::ReconnectFailed::attempts: u32
pub nanobook_broker::BrokerError::ReconnectFailed::reason: alloc::string::String
pub nanobook_broker::BrokerError::ValueOutOfRange
pub nanobook_broker::BrokerError::ValueOutOfRange::field: &'static str
pub nanobook_broker::BrokerError::ValueOutOfRange::value: f64
pub enum nanobook_broker::BrokerOrderType
pub nanobook_broker::BrokerOrderType::Limit(nanobook::types::Price)
pub nanobook_broker::BrokerOrderType::Market
pub enum nanobook_broker::BrokerSide
pub nanobook_broker::BrokerSide::Buy
pub nanobook_broker::BrokerSide::Sell
pub enum nanobook_broker::OrderState
pub nanobook_broker::OrderState::Cancelled
pub nanobook_broker::OrderState::Filled
pub nanobook_broker::OrderState::PartiallyFilled
pub nanobook_broker::OrderState::Pending
pub nanobook_broker::OrderState::Rejected
pub nanobook_broker::OrderState::Submitted
pub struct nanobook_broker::Account
pub nanobook_broker::Account::buying_power_cents: i64
pub nanobook_broker::Account::cash_cents: i64
pub nanobook_broker::Account::equity_cents: i64
pub nanobook_broker::Account::gross_position_value_cents: i64
pub struct nanobook_broker::BestQuote
pub nanobook_broker::BestQuote::ask_cents: i64
pub nanobook_broker::BestQuote::bid_cents: i64
pub struct nanobook_broker::BrokerOrder
pub nanobook_broker::BrokerOrder::client_order_id: core::option::Option<nanobook_broker::ClientOrderId>
pub nanobook_broker::BrokerOrder::order_type: nanobook_broker::BrokerOrderType
pub nanobook_broker::BrokerOrder::quantity: u64
pub nanobook_broker::BrokerOrder::side: nanobook_broker::BrokerSide
pub nanobook_broker::BrokerOrder::symbol: nanobook::types::Symbol
pub struct nanobook_broker::BrokerOrderStatus
pub nanobook_broker::BrokerOrderStatus::avg_fill_price_cents: i64
pub nanobook_broker::BrokerOrderStatus::filled_quantity: u64
pub nanobook_broker::BrokerOrderStatus::id: nanobook_broker::OrderId
pub nanobook_broker::BrokerOrderStatus::remaining_quantity: u64
pub nanobook_broker::BrokerOrderStatus::status: nanobook_broker::OrderState
pub struct nanobook_broker::ClientOrderId(_)
impl nanobook_broker::ClientOrderId
pub fn nanobook_broker::ClientOrderId::as_str(&self) -> &str
pub fn nanobook_broker::ClientOrderId::derive(scope: &str, symbol: &str, side: nanobook_broker::BrokerSide, qty: u64) -> Self
pub fn nanobook_broker::ClientOrderId::new(value: impl core::convert::Into<alloc::string::String>) -> core::result::Result<Self, nanobook_broker::error::BrokerError>
pub struct nanobook_broker::OrderId(pub u64)
pub struct nanobook_broker::Position
pub nanobook_broker::Position::avg_cost_cents: i64
pub nanobook_broker::Position::market_value_cents: i64
pub nanobook_broker::Position::quantity: i64
pub nanobook_broker::Position::symbol: nanobook::types::Symbol
pub nanobook_broker::Position::unrealized_pnl_cents: i64
pub struct nanobook_broker::Quote
pub nanobook_broker::Quote::ask_cents: i64
pub nanobook_broker::Quote::bid_cents: i64
pub nanobook_broker::Quote::last_cents: i64
pub nanobook_broker::Quote::symbol: nanobook::types::Symbol
pub nanobook_broker::Quote::timestamp: std::time::SystemTime
pub nanobook_broker::Quote::volume: u64
impl nanobook_broker::Quote
pub fn nanobook_broker::Quote::is_stale(&self, threshold_sec: u64) -> bool
pub trait nanobook_broker::Broker
pub fn nanobook_broker::Broker::account(&self) -> core::result::Result<nanobook_broker::Account, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::Broker::cancel_order(&self, id: nanobook_broker::OrderId) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::Broker::connect(&mut self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::Broker::disconnect(&mut self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::Broker::open_orders(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::BrokerOrderStatus>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::Broker::order_status(&self, id: nanobook_broker::OrderId) -> core::result::Result<nanobook_broker::BrokerOrderStatus, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::Broker::positions(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::Position>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::Broker::quote(&self, symbol: &nanobook::types::Symbol) -> core::result::Result<nanobook_broker::Quote, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::Broker::submit_order(&self, order: &nanobook_broker::BrokerOrder) -> core::result::Result<nanobook_broker::OrderId, nanobook_broker::error::BrokerError>
impl nanobook_broker::Broker for nanobook_broker::binance::BinanceBroker
pub fn nanobook_broker::binance::BinanceBroker::account(&self) -> core::result::Result<nanobook_broker::Account, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::cancel_order(&self, id: nanobook_broker::OrderId) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::connect(&mut self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::disconnect(&mut self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::open_orders(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::BrokerOrderStatus>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::order_status(&self, id: nanobook_broker::OrderId) -> core::result::Result<nanobook_broker::BrokerOrderStatus, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::positions(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::Position>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::quote(&self, symbol: &nanobook::types::Symbol) -> core::result::Result<nanobook_broker::Quote, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::binance::BinanceBroker::submit_order(&self, order: &nanobook_broker::BrokerOrder) -> core::result::Result<nanobook_broker::OrderId, nanobook_broker::error::BrokerError>
impl nanobook_broker::Broker for nanobook_broker::ibkr::IbkrBroker
pub fn nanobook_broker::ibkr::IbkrBroker::account(&self) -> core::result::Result<nanobook_broker::Account, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::cancel_order(&self, id: nanobook_broker::OrderId) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::connect(&mut self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::disconnect(&mut self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::open_orders(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::BrokerOrderStatus>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::order_status(&self, id: nanobook_broker::OrderId) -> core::result::Result<nanobook_broker::BrokerOrderStatus, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::positions(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::Position>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::quote(&self, symbol: &nanobook::types::Symbol) -> core::result::Result<nanobook_broker::Quote, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::ibkr::IbkrBroker::submit_order(&self, order: &nanobook_broker::BrokerOrder) -> core::result::Result<nanobook_broker::OrderId, nanobook_broker::error::BrokerError>
impl nanobook_broker::Broker for nanobook_broker::mock::MockBroker
pub fn nanobook_broker::mock::MockBroker::account(&self) -> core::result::Result<nanobook_broker::Account, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::mock::MockBroker::cancel_order(&self, id: nanobook_broker::OrderId) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::mock::MockBroker::connect(&mut self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::mock::MockBroker::disconnect(&mut self) -> core::result::Result<(), nanobook_broker::error::BrokerError>
pub fn nanobook_broker::mock::MockBroker::open_orders(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::BrokerOrderStatus>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::mock::MockBroker::order_status(&self, id: nanobook_broker::OrderId) -> core::result::Result<nanobook_broker::BrokerOrderStatus, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::mock::MockBroker::positions(&self) -> core::result::Result<alloc::vec::Vec<nanobook_broker::Position>, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::mock::MockBroker::quote(&self, symbol: &nanobook::types::Symbol) -> core::result::Result<nanobook_broker::Quote, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::mock::MockBroker::submit_order(&self, order: &nanobook_broker::BrokerOrder) -> core::result::Result<nanobook_broker::OrderId, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::f64_cents_checked(value: f64, field: &'static str) -> core::result::Result<i64, nanobook_broker::error::BrokerError>
pub fn nanobook_broker::f64_to_fixed_checked(value: f64, scale: f64, field: &'static str) -> core::result::Result<i64, nanobook_broker::error::BrokerError>
