fn for_each_pruning(
        &self,
        threshold: Score,
        reader: &SegmentReader,
        callback: &mut dyn FnMut(DocId, Score) -> Score,
    ) -> crate::Result<()> {
        let mut scorer = self.scorer(reader, 1.0)?;
        for_each_pruning_scorer(&mut scorer, threshold, callback);
        Ok(())
    }
/// Calls `callback` with all of the `(doc, score)` for which score
/// is exceeding a given threshold.
///
/// This method is useful for the TopDocs collector.
/// For all docsets, the blanket implementation has the benefit
/// of prefiltering (doc, score) pairs, avoiding the
/// virtual dispatch cost.
///
/// More importantly, it makes it possible for scorers to implement
/// important optimization (e.g. BlockWAND for union).
Calls `callback` with all of the `(doc, score)` for which score
is exceeding a given threshold.

This method is useful for the TopDocs collector.
For all docsets, the blanket implementation has the benefit
of prefiltering (doc, score) pairs, avoiding the
virtual dispatch cost.

More importantly, it makes it possible for scorers to implement
important optimization .
Calls ` callback ` with all of the ` ( doc score ) ` for which score is exceeding a given threshold . This method is useful for the TopDocs collector . For all docsets the blanket implementation has the benefit of prefiltering ( doc score ) pairs avoiding the virtual dispatch cost . More importantly it makes it possible for scorers to implement important optimization .
fn for_each_pruning(
        &self,
        threshold: Score,
        reader: &SegmentReader,
        callback: &mut dyn FnMut(DocId, Score) -> Score,
    ) -> crate::Result<()> {
        let mut scorer = self.scorer(reader, 1.0)?;
        for_each_pruning_scorer(&mut scorer, threshold, callback);
        Ok(())
    }
fn for_each_pruning ( & self , threshold : Score , reader : & SegmentReader , callback : & mut dyn FnMut ( DocId , Score ) -> Score , ) -> crate :: Result < ( ) > { let mut scorer = self . scorer ( reader , 1.0 ) ? ; for_each_pruning_scorer ( & mut scorer , threshold , callback ) ; Ok ( ( ) ) }
Calls `callback` with all of the `(doc, score)` for which score
is exceeding a given threshold.
Calls ` callback ` with all of the ` ( doc score ) ` for which score is exceeding a given threshold .
&self
threshold
Score
reader
&SegmentReader
callback
&mut dyn FnMut(DocId, Score) -> Score
&self
threshold
Score
reader
&SegmentReader
callback
&mut dyn FnMut(DocId, Score) -> Score