pub struct BalancerConfig {
pub min_trade_percent: Decimal,
pub min_trade_value: Decimal,
pub tolerance_percent: Decimal,
pub order_delay_ms: u64,
pub dry_run: bool,
pub max_orders_per_cycle: usize,
pub min_profit_percent_for_close: Option<Decimal>,
}Expand description
Configuration for the balancer engine.
Fields§
§min_trade_percent: DecimalMinimum trade size as percentage of portfolio.
min_trade_value: DecimalMinimum trade value in base currency.
tolerance_percent: DecimalTolerance for considering allocation “close enough”.
order_delay_ms: u64Delay between consecutive orders (milliseconds).
dry_run: boolWhether to actually execute trades or just simulate.
max_orders_per_cycle: usizeMaximum number of orders per rebalancing cycle.
min_profit_percent_for_close: Option<Decimal>Minimum profit percentage required for selling a position.
Trait Implementations§
Source§impl Clone for BalancerConfig
impl Clone for BalancerConfig
Source§impl Debug for BalancerConfig
impl Debug for BalancerConfig
Auto Trait Implementations§
impl Forget for BalancerConfig
impl Freeze for BalancerConfig
impl Move for BalancerConfig
impl RefUnwindSafe for BalancerConfig
impl Send for BalancerConfig
impl Sync for BalancerConfig
impl Unpin for BalancerConfig
impl UnsafeUnpin for BalancerConfig
impl UnwindSafe for BalancerConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more