pub struct Trust { /* private fields */ }Expand description
Trust of every (engineer, area) that authored a lesson in one store.
Implementations§
Source§impl Trust
impl Trust
Sourcepub fn compute(lessons: &[Challenge], outcomes: &[Outcome]) -> Trust
pub fn compute(lessons: &[Challenge], outcomes: &[Outcome]) -> Trust
From a store’s lessons (latest versions) and its outcomes.
Sourcepub fn of(&self, engineer: &str, area_name: &str) -> f64
pub fn of(&self, engineer: &str, area_name: &str) -> f64
engineer’s trust in area; neutral when they have no lesson there.
Sourcepub fn lesson(&self, c: &Challenge) -> f64
pub fn lesson(&self, c: &Challenge) -> f64
Mean trust of a lesson’s authors in its area; neutral without known authors.
Sourcepub fn rows(&self) -> impl Iterator<Item = (&str, &str, Evidence)>
pub fn rows(&self) -> impl Iterator<Item = (&str, &str, Evidence)>
Every (engineer, area) with its evidence, sorted by engineer then area.
Sourcepub fn has_evidence(&self) -> bool
pub fn has_evidence(&self) -> bool
Whether any (engineer, area) has evidence beyond the neutral prior.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Trust
impl RefUnwindSafe for Trust
impl Send for Trust
impl Sync for Trust
impl Unpin for Trust
impl UnsafeUnpin for Trust
impl UnwindSafe for Trust
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