feat: Remove the State from most of the code

This commit is contained in:
Clément Renault
2018-09-09 13:35:12 +02:00
parent 31e04f0120
commit a49a21ac15
13 changed files with 983 additions and 491 deletions

View File

@ -13,10 +13,7 @@ fn search(metadata: &Metadata, database: &DB, query: &str) {
automatons.push(lev);
}
let map = metadata.as_map();
let indexes = metadata.as_indexes();
let mut stream = RankedStream::new(&map, &indexes, automatons, 20);
let mut stream = RankedStream::new(&metadata, automatons, 20);
while let Some(document) = stream.next() {
print!("{:?}", document.document_id);