pub fn new_intervals(&self, settings: &settings::TagSettings, priority: Priority, modifier: Ease, max_interval: chrono::Duration) -> [chrono::Duration; SCORES] {
        match self.state {
            CardState::New => [
                self.new_interval_new(settings, Score::Fail, max_interval),
                self.new_interval_new(settings, Score::Hard, max_interval),
                self.new_interval_new(settings, Score::Okay, max_interval),
                self.new_interval_new(settings, Score::Good, max_interval),
                self.new_interval_new(settings, Score::Easy, max_interval),
            ],
            CardState::Learning(step) => [
                self.new_interval_learning(settings, Score::Fail, step, max_interval),
                self.new_interval_learning(settings, Score::Hard, step, max_interval),
                self.new_interval_learning(settings, Score::Okay, step, max_interval),
                self.new_interval_learning(settings, Score::Good, step, max_interval),
                self.new_interval_learning(settings, Score::Easy, step, max_interval),
            ],
            CardState::Relearning(step) => [
                self.new_interval_relearning(settings, Score::Fail, step, max_interval),
                self.new_interval_relearning(settings, Score::Hard, step, max_interval),
                self.new_interval_relearning(settings, Score::Okay, step, max_interval),
                self.new_interval_relearning(settings, Score::Good, step, max_interval),
                self.new_interval_relearning(settings, Score::Easy, step, max_interval),
            ],
            CardState::Learnt => [
                // If the card was failed, we enter relearning.
                settings.relearning_intervals[0],
                self.new_interval_learnt(settings, Score::Hard, priority, modifier, max_interval),
                self.new_interval_learnt(settings, Score::Okay, priority, modifier, max_interval),
                self.new_interval_learnt(settings, Score::Good, priority, modifier, max_interval),
                self.new_interval_learnt(settings, Score::Easy, priority, modifier, max_interval),
            ],
        }
    }
/// The updated intervals, depending on score.
The updated intervals, depending on score.
The updated intervals depending on score .
pub fn new_intervals(&self, settings: &settings::TagSettings, priority: Priority, modifier: Ease, max_interval: chrono::Duration) -> [chrono::Duration; SCORES] {
        match self.state {
            CardState::New => [
                self.new_interval_new(settings, Score::Fail, max_interval),
                self.new_interval_new(settings, Score::Hard, max_interval),
                self.new_interval_new(settings, Score::Okay, max_interval),
                self.new_interval_new(settings, Score::Good, max_interval),
                self.new_interval_new(settings, Score::Easy, max_interval),
            ],
            CardState::Learning(step) => [
                self.new_interval_learning(settings, Score::Fail, step, max_interval),
                self.new_interval_learning(settings, Score::Hard, step, max_interval),
                self.new_interval_learning(settings, Score::Okay, step, max_interval),
                self.new_interval_learning(settings, Score::Good, step, max_interval),
                self.new_interval_learning(settings, Score::Easy, step, max_interval),
            ],
            CardState::Relearning(step) => [
                self.new_interval_relearning(settings, Score::Fail, step, max_interval),
                self.new_interval_relearning(settings, Score::Hard, step, max_interval),
                self.new_interval_relearning(settings, Score::Okay, step, max_interval),
                self.new_interval_relearning(settings, Score::Good, step, max_interval),
                self.new_interval_relearning(settings, Score::Easy, step, max_interval),
            ],
            CardState::Learnt => [
                // If the card was failed, we enter relearning.
                settings.relearning_intervals[0],
                self.new_interval_learnt(settings, Score::Hard, priority, modifier, max_interval),
                self.new_interval_learnt(settings, Score::Okay, priority, modifier, max_interval),
                self.new_interval_learnt(settings, Score::Good, priority, modifier, max_interval),
                self.new_interval_learnt(settings, Score::Easy, priority, modifier, max_interval),
            ],
        }
    }
pub fn new_intervals ( & self , settings : & settings :: TagSettings , priority : Priority , modifier : Ease , max_interval : chrono :: Duration ) -> [ chrono :: Duration ; SCORES ] { match self . state { CardState :: New => [ self . new_interval_new ( settings , Score :: Fail , max_interval ) , self . new_interval_new ( settings , Score :: Hard , max_interval ) , self . new_interval_new ( settings , Score :: Okay , max_interval ) , self . new_interval_new ( settings , Score :: Good , max_interval ) , self . new_interval_new ( settings , Score :: Easy , max_interval ) , ] , CardState :: Learning ( step ) => [ self . new_interval_learning ( settings , Score :: Fail , step , max_interval ) , self . new_interval_learning ( settings , Score :: Hard , step , max_interval ) , self . new_interval_learning ( settings , Score :: Okay , step , max_interval ) , self . new_interval_learning ( settings , Score :: Good , step , max_interval ) , self . new_interval_learning ( settings , Score :: Easy , step , max_interval ) , ] , CardState :: Relearning ( step ) => [ self . new_interval_relearning ( settings , Score :: Fail , step , max_interval ) , self . new_interval_relearning ( settings , Score :: Hard , step , max_interval ) , self . new_interval_relearning ( settings , Score :: Okay , step , max_interval ) , self . new_interval_relearning ( settings , Score :: Good , step , max_interval ) , self . new_interval_relearning ( settings , Score :: Easy , step , max_interval ) , ] , CardState :: Learnt => [ // If the card was failed, we enter relearning. settings . relearning_intervals [ 0 ] , self . new_interval_learnt ( settings , Score :: Hard , priority , modifier , max_interval ) , self . new_interval_learnt ( settings , Score :: Okay , priority , modifier , max_interval ) , self . new_interval_learnt ( settings , Score :: Good , priority , modifier , max_interval ) , self . new_interval_learnt ( settings , Score :: Easy , priority , modifier , max_interval ) , ] , } }
The updated intervals, depending on score.
The updated intervals depending on score .
&self
settings
&settings::TagSettings
priority
Priority
modifier
Ease
max_interval
chrono::Duration
&self
settings
&settings::TagSettings
priority
Priority
modifier
Ease
max_interval
chrono::Duration