pub trait ConditionForSegment<T>: Clone {
type Type: CheckCondition<T>;
// Required method
fn for_segment(&self, reader: &SegmentReader) -> Self::Type;
}
Expand description
A trait that allows defining arbitrary conditions to be checked before considering a matching document for inclusion in the top results.
Required Associated Types§
Sourcetype Type: CheckCondition<T>
type Type: CheckCondition<T>
The concrete type of the result from calling for_segment
Required Methods§
Sourcefn for_segment(&self, reader: &SegmentReader) -> Self::Type
fn for_segment(&self, reader: &SegmentReader) -> Self::Type
Creates a Self::Type
instance responsible for checking if
the matching documents in the given segment reader are to
be considered as collection candidates.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.