mirror of
https://github.com/quickwit-oss/tantivy.git
synced 2026-01-08 18:12:55 +00:00
Minor Doc Changes (#206)
* Various small documentation tweaks * walking through the docs * Update lib.rs * Update lib.rs * Update mod.rs
This commit is contained in:
committed by
Paul Masurel
parent
92a3f3981f
commit
2bb85ed575
@@ -1,3 +1,6 @@
|
||||
/*!
|
||||
Collector module
|
||||
*/
|
||||
use SegmentReader;
|
||||
use SegmentLocalId;
|
||||
use DocId;
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/*!
|
||||
Fast fields is a column oriented storage storage.
|
||||
Fast fields is a column oriented storage.
|
||||
|
||||
It is the equivalent of `Lucene`'s `DocValues`.
|
||||
|
||||
|
||||
24
src/lib.rs
24
src/lib.rs
@@ -103,24 +103,12 @@ mod analyzer;
|
||||
mod datastruct;
|
||||
|
||||
pub mod termdict;
|
||||
|
||||
/// Row-oriented, slow, compressed storage of documents
|
||||
pub mod store;
|
||||
|
||||
/// Query module
|
||||
pub mod query;
|
||||
|
||||
pub mod directory;
|
||||
|
||||
/// Collector module
|
||||
pub mod collector;
|
||||
|
||||
/// Postings module (also called inverted index)
|
||||
pub mod postings;
|
||||
|
||||
/// Schema
|
||||
pub mod schema;
|
||||
|
||||
pub mod fastfield;
|
||||
|
||||
|
||||
@@ -156,15 +144,19 @@ pub mod merge_policy {
|
||||
pub use indexer::DefaultMergePolicy;
|
||||
}
|
||||
|
||||
/// u32 identifying a document within a segment.
|
||||
/// Documents have their doc id assigned incrementally,
|
||||
/// A `u32` identifying a document within a segment.
|
||||
/// Documents have their `DocId` assigned incrementally,
|
||||
/// as they are added in the segment.
|
||||
pub type DocId = u32;
|
||||
|
||||
/// f32 the score of a document.
|
||||
/// A f32 that represents the relevance of the document to the query
|
||||
///
|
||||
/// This is modelled internally as a `f32`. The
|
||||
/// larger the number, the more relevant the document
|
||||
/// to the search
|
||||
pub type Score = f32;
|
||||
|
||||
/// A segment local id identifies a segment.
|
||||
/// A `SegmentLocalId` identifies a segment.
|
||||
/// It only makes sense for a given searcher.
|
||||
pub type SegmentLocalId = u32;
|
||||
|
||||
|
||||
@@ -1,3 +1,7 @@
|
||||
/*!
|
||||
Postings module (also called inverted index)
|
||||
*/
|
||||
|
||||
/// Postings module
|
||||
///
|
||||
/// Postings, also called inverted lists, is the key datastructure
|
||||
|
||||
@@ -1,7 +1,8 @@
|
||||
/// Query module
|
||||
///
|
||||
/// The query module regroups all of tantivy's query objects
|
||||
///
|
||||
/*!
|
||||
Query module
|
||||
|
||||
The query module regroups all of tantivy's query objects
|
||||
*/
|
||||
|
||||
mod query;
|
||||
mod boolean_query;
|
||||
|
||||
@@ -2,7 +2,7 @@ use query::Occur;
|
||||
|
||||
|
||||
/// An `OccurFilter` represents a filter over a bitset of
|
||||
// at most 64 elements.
|
||||
/// at most 64 elements.
|
||||
///
|
||||
/// It wraps some simple bitmask to compute the filter
|
||||
/// rapidly.
|
||||
|
||||
@@ -7,7 +7,8 @@ use query::Weight;
|
||||
use Result;
|
||||
|
||||
|
||||
/// `PhraseQuery` matches a specific sequence of word.
|
||||
/// `PhraseQuery` matches a specific sequence of words.
|
||||
///
|
||||
/// For instance the phrase query for `"part time"` will match
|
||||
/// the sentence
|
||||
///
|
||||
|
||||
@@ -8,7 +8,10 @@ use std::fmt;
|
||||
use std::any::Any;
|
||||
|
||||
|
||||
/// Query trait are in charge of defining :
|
||||
/// The `Query` trait defines a set of documents and a scoring method
|
||||
/// for those documents.
|
||||
///
|
||||
/// The `Query` trait is in charge of defining :
|
||||
///
|
||||
/// - a set of documents
|
||||
/// - a way to score these documents
|
||||
@@ -68,7 +71,10 @@ pub trait Query: fmt::Debug {
|
||||
let mut segment_search_timer = search_timer.open("segment_search");
|
||||
{
|
||||
let _ = segment_search_timer.open("set_segment");
|
||||
try!(collector.set_segment(segment_ord as SegmentLocalId, segment_reader));
|
||||
try!(collector.set_segment(
|
||||
segment_ord as SegmentLocalId,
|
||||
segment_reader,
|
||||
));
|
||||
}
|
||||
let mut scorer = try!(weight.scorer(segment_reader));
|
||||
{
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/*!
|
||||
|
||||
|
||||
# Schema definition
|
||||
# Setting your schema in Tantivy
|
||||
|
||||
Tantivy has a very strict schema.
|
||||
The schema defines information about the fields your index contains, that is, for each field:
|
||||
|
||||
Reference in New Issue
Block a user