kvarn_search

Struct SearchEngineHandle

source
pub struct SearchEngineHandle { /* private fields */ }

Implementations§

source§

impl SearchEngineHandle

source

pub async fn index(&self, host: &Host, documents: impl Iterator<Item = String>)

This spawns a new task for every request it makes. The requests are processed in parallell - this should return within the longest response duration.

source

pub async fn index_all(&self, host: &Host)

Indexes all the pages in host.

Read this section of an article about how it fetches this.

source

pub async fn watch( &self, host_name: impl Into<String>, collection: Arc<HostCollection>, )