[−][src]Struct supermemo2::Item
A struct that holds the essential metadata for an item using the supermemo2 algorithm.
Methods
impl Item
[src]
pub fn new() -> Self
[src]
Return an Item
with no reviews and the default E-factor of 2.5.
pub fn from(repetitions: usize, efactor: f64) -> Self
[src]
Create an Item
that has already been reviewed by specifying the
number of repetitions done and the current E-factor.
pub fn interval(&self) -> usize
[src]
Returns the current interval of the card. The interval is defined as the time in days since the previous review after which this item will be due for review.
pub fn answer(&self, quality: &Quality) -> Self
[src]
Returns a new Item
for an answer to this Item
with the provided Quality
.
pub fn answer_mut(&mut self, quality: &Quality)
[src]
Updates an Item
for an answer with the provided Quality
.
Trait Implementations
Auto Trait Implementations
impl Send for Item
impl Sync for Item
impl Unpin for Item
impl UnwindSafe for Item
impl RefUnwindSafe for Item
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,