colibri.qdrant / lib /segment /src /index /hnsw_index /build_condition_checker.rs
Gouzi Mohaled
Ajout du dossier lib
84d2a97
raw
history blame contribute delete
566 Bytes
use common::types::PointOffsetType;
use crate::index::visited_pool::VisitedListHandle;
use crate::payload_storage::FilterContext;
pub struct BuildConditionChecker<'a> {
pub filter_list: &'a VisitedListHandle<'a>,
pub current_point: PointOffsetType,
}
impl<'a> FilterContext for BuildConditionChecker<'a> {
fn check(&self, point_id: PointOffsetType) -> bool {
if point_id == self.current_point {
return false; // Do not match current point while inserting it (second time)
}
self.filter_list.check(point_id)
}
}