indicium/simple/
mod.rs

1//! The simple Indicium search implementation. Fewer bells-and-whistles but
2//! easier to use than the other options.
3//!
4//! There might be more search implementations in future versions.
5
6#[cfg(all(feature = "eddie", feature = "rapidfuzz"))]
7compile_error!("features `eddie` and `rapidfuzz` cannot both be enabled");
8
9#[cfg(all(feature = "eddie", feature = "strsim"))]
10compile_error!("features `eddie` and `strsim` cannot both be enabled");
11
12#[cfg(all(feature = "rapidfuzz", feature = "strsim"))]
13compile_error!("features `rapidfuzz` and `strsim` cannot both be enabled");
14
15#[cfg(all(feature = "ahash", feature = "gxhash"))]
16compile_error!("features `ahash` and `gxhash` cannot both be enabled");
17
18#[cfg(all(feature = "ahash", feature = "rustc-hash"))]
19compile_error!("features `ahash` and `rustc-hash` cannot both be enabled");
20
21#[cfg(all(feature = "gxhash", feature = "rustc-hash"))]
22compile_error!("features `gxhash` and `rustc-hash` cannot both be enabled");
23
24// Directories:
25mod autocomplete;
26mod internal;
27mod search;
28
29// Methods, structs & implementations:
30mod autocomplete_type;
31mod builder;
32mod clear;
33mod default;
34mod deref;
35mod deref_mut;
36mod dump_keyword;
37mod indexable;
38mod insert;
39mod max_keys_per_keyword;
40mod new;
41mod remove;
42mod replace;
43mod search_index;
44mod search_type;
45mod tests;
46
47// For debug builds only:
48#[cfg(debug_assertions)]
49mod profile;
50
51// Exports:
52pub use crate::simple::autocomplete_type::AutocompleteType;
53pub use crate::simple::builder::SearchIndexBuilder;
54pub use crate::simple::indexable::Indexable;
55pub use crate::simple::internal::fuzzers::{
56    RapidfuzzMetric,
57    EddieMetric,
58    StrsimMetric
59};
60pub use crate::simple::search_index::SearchIndex;
61pub use crate::simple::search_type::SearchType;