pub struct IndexBuilder { /* private fields */ }Expand description
Builds an index the way addok’s batch import does: prepare_housenumbers,
then the housenumbers, fields, pairs, filters and geohash indexers, then
addok ngrams.
Implementations§
Source§impl IndexBuilder
impl IndexBuilder
pub fn new(profile: Arc<dyn Profile>) -> Self
pub fn documents(&self) -> usize
Sourcepub fn skipped(&self) -> usize
pub fn skipped(&self) -> usize
Documents rejected so far (missing required field or coordinates).
Sourcepub fn add_document(&mut self, doc: Document) -> Result<bool, GeocoderError>
pub fn add_document(&mut self, doc: Document) -> Result<bool, GeocoderError>
Index one document. Returns false when it is rejected.
Auto Trait Implementations§
impl !RefUnwindSafe for IndexBuilder
impl !UnwindSafe for IndexBuilder
impl Forget for IndexBuilder
impl Freeze for IndexBuilder
impl Move for IndexBuilder
impl Send for IndexBuilder
impl Sync for IndexBuilder
impl Unpin for IndexBuilder
impl UnsafeUnpin for IndexBuilder
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