pub struct Card { /* private fields */ }
Implementations§
Source§impl Card
impl Card
pub fn trivial(&self) -> bool
pub fn reviewable(&self) -> bool
pub fn clone_base(&self) -> RawCard
pub fn attributes_on_class(&self) -> Option<Vec<Attrv2>>
pub fn attributes(&self) -> Option<Vec<Attrv2>>
pub fn parent_classes(&self) -> HashSet<CardId>
pub fn get_attr(&self, id: AttributeId) -> Option<Attrv2>
pub fn attr_id(&self) -> Option<AttributeId>
Sourcepub fn attribute_instance(&self) -> CardId
pub fn attribute_instance(&self) -> CardId
gets the instance that this attribute card is based on.
pub fn uses_attr_id(&self, id: AttributeId) -> bool
pub fn front_audio(&self) -> Option<&Audio>
pub fn back_audio(&self) -> Option<&Audio>
pub fn front_audio_id(&self) -> Option<AudioId>
pub fn back_audio_id(&self) -> Option<AudioId>
pub fn card_type(&self) -> CType
pub fn dependents_ids(&self) -> BTreeSet<CardId>
pub fn dependents(&self) -> BTreeSet<Arc<Self>>
pub fn add_review(&mut self, recall: Recall)
pub fn time_provider(&self) -> FsTime
pub fn lapses_last_month(&self) -> u32
pub fn lapses_last_week(&self) -> u32
pub fn lapses_last_day(&self) -> u32
pub fn from_parts( base: RawCard, history: History, metadata: Metadata, card_provider: CardProvider, recaller: SimpleRecall, front_audio: Option<Audio>, back_audio: Option<Audio>, ) -> Self
pub fn namespace(&self) -> Option<CardId>
pub fn is_finished(&self) -> bool
Sourcepub fn attribute_cards(&self) -> HashSet<CardId>
pub fn attribute_cards(&self) -> HashSet<CardId>
which attribute cards describe this instance?
pub fn is_attribute(&self) -> bool
pub fn is_instance(&self) -> bool
pub fn is_class(&self) -> bool
pub fn is_instance_of(&self, _class: CardId) -> bool
pub async fn set_ref(self, reff: CardId) -> Result<Card, EventError<RawCard>>
pub fn add_dependency( &mut self, dependency: CardId, ) -> Result<(), EventError<RawCard>>
pub fn back_side(&self) -> Option<&BackSide>
pub fn recursive_dependents(&self) -> HashSet<CardId>
pub fn recursive_dependencies(&self) -> Vec<CardId> ⓘ
pub fn min_rec_stability(&self) -> f32
pub fn min_rec_recall_rate(&self) -> RecallRate
pub fn display_backside(&self) -> &str
pub fn back_refs(&self) -> Option<NonEmpty<CardId>>
pub fn history(&self) -> &History
pub fn recall_rate_at(&self, current_unix: Duration) -> Option<RecallRate>
Sourcepub fn full_history(&self) -> History
pub fn full_history(&self) -> History
Full history includes all the successful reviews of cards that are dependent on this card. the idea is, if you can successfully recall a dependent card, then implicitly you know this card too. It does not include unsuccesful reviews of dependents because you may have failed to realize that card either due to the card itself or another dependency.
pub fn full_recall_rate(&self) -> Option<RecallRate>
pub fn recall_rate(&self) -> Option<RecallRate>
pub fn maturity_days(&self) -> Option<f32>
pub fn maturity(&self) -> Option<Duration>
pub fn print(&self) -> String
pub fn backside(&self) -> &EvalText
pub fn name(&self) -> &EvalText
pub fn name_textdata(&self) -> TextData
pub fn front_side(&self) -> &EvalText
pub fn is_pending(&self) -> bool
pub fn is_suspended(&self) -> bool
pub fn set_suspend(&mut self, suspend: bool)
pub fn time_since_last_review(&self) -> Option<Duration>
pub fn id(&self) -> CardId
pub fn explicit_dependencies(&self) -> HashSet<CardId>
pub fn dependencies(&self) -> HashSet<CardId>
pub fn lapses(&self) -> u32
Trait Implementations§
Source§impl Ord for Card
impl Ord for Card
Source§impl PartialOrd for Card
impl PartialOrd for Card
impl Eq for Card
Auto Trait Implementations§
impl Freeze for Card
impl RefUnwindSafe for Card
impl Send for Card
impl Sync for Card
impl Unpin for Card
impl UnwindSafe for Card
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Comparable<K> for Q
impl<Q, K> Comparable<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more