Simplify handling of ef parameters

This commit is contained in:
Dirkjan Ochtman 2021-01-14 16:55:47 +01:00
parent b865f2f287
commit 47f26978f5
1 changed files with 1 additions and 4 deletions

View File

@ -38,11 +38,8 @@ impl Builder {
///
/// If the `efConstruction` parameter is not already set, it will be set
/// to the same value as `ef` by default.
pub fn ef(mut self, ef: usize) -> Self {
pub fn ef_search(mut self, ef: usize) -> Self {
self.ef_search = Some(ef);
if self.ef_construction.is_none() {
self.ef_construction = Some(ef);
}
self
}