pub struct ItemStats {
pub item: String,
// some fields omitted
}
A representation of statistics for a single item
Compare the score of two items given a sort method
Change the half life of the item, maintaining the same frecency
Calculate the frecency of the item
update the frecency of the item by the given weight
Update the number of accesses of the item by the given weight
Update the time the item was last accessed
Reset the reference time and recalculate the last_accessed time
Return the number of seconds since the item was last accessed
sort method if show_stats
is true
Performs copy-assignment from source
. Read more
Creates owned data from borrowed data, usually by cloning. Read more
🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more
🔬 This is a nightly-only experimental API. (try_from
)
The type returned in the event of a conversion error.
🔬 This is a nightly-only experimental API. (try_from
)
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more
🔬 This is a nightly-only experimental API. (try_from
)
The type returned in the event of a conversion error.
🔬 This is a nightly-only experimental API. (try_from
)
🔬 This is a nightly-only experimental API. (get_type_id
)
this method will likely be replaced by an associated static