pub struct EvaluationRef<'a> { /* private fields */ }Expand description
A temporary assessment borrowed during a lending comparison. The view cannot outlive the callback or retain metric scratch. Native typed results remain available from the ordinary owned scoring interface.
Implementations§
Source§impl<'a> EvaluationRef<'a>
impl<'a> EvaluationRef<'a>
Sourcepub fn new<T: Evaluation>(value: &'a T) -> Self
pub fn new<T: Evaluation>(value: &'a T) -> Self
Borrow a concrete assessment without boxing or copying its maps.
Sourcepub fn visit_scores(self, visitor: impl FnMut(Score<'a>))
pub fn visit_scores(self, visitor: impl FnMut(Score<'a>))
Visit every named scalar in native output order.
Sourcepub fn visit_maps(self, visitor: impl FnMut(MapView<'a>))
pub fn visit_maps(self, visitor: impl FnMut(MapView<'a>))
Visit every native map in output order.
Trait Implementations§
Source§impl<'a> Clone for EvaluationRef<'a>
impl<'a> Clone for EvaluationRef<'a>
Source§fn clone(&self) -> EvaluationRef<'a>
fn clone(&self) -> EvaluationRef<'a>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl<'a> Copy for EvaluationRef<'a>
Auto Trait Implementations§
impl<'a> !RefUnwindSafe for EvaluationRef<'a>
impl<'a> !Send for EvaluationRef<'a>
impl<'a> !Sync for EvaluationRef<'a>
impl<'a> !UnwindSafe for EvaluationRef<'a>
impl<'a> Freeze for EvaluationRef<'a>
impl<'a> Unpin for EvaluationRef<'a>
impl<'a> UnsafeUnpin for EvaluationRef<'a>
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