pub struct RegimeDetector { /* private fields */ }Implementations§
Source§impl RegimeDetector
impl RegimeDetector
pub fn new(strategy_group: StrategyGroup) -> Self
Sourcepub fn detect(&mut self, indicators: &TechnicalIndicators, now: u64) -> &str
pub fn detect(&mut self, indicators: &TechnicalIndicators, now: u64) -> &str
Detect regime from current indicators. Returns the regime name.
pub fn current_regime(&self) -> &str
pub fn regime_changed(&self) -> bool
pub fn previous_regime(&self) -> Option<&str>
Sourcepub fn current_playbook(&self) -> Option<&Playbook>
pub fn current_playbook(&self) -> Option<&Playbook>
Look up the playbook for the current regime.
pub fn strategy_group(&self) -> &StrategyGroup
Auto Trait Implementations§
impl Freeze for RegimeDetector
impl RefUnwindSafe for RegimeDetector
impl Send for RegimeDetector
impl Sync for RegimeDetector
impl Unpin for RegimeDetector
impl UnsafeUnpin for RegimeDetector
impl UnwindSafe for RegimeDetector
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