Method Phrase
- Namespace
- TantivyDotNet
- Assembly
- TantivyDotNet.dll
Phrase(string, string, int)
Matches documents where the words of text appear in order in
field. The text is analyzed with the field's tokenizer.
public static PhraseQuery Phrase(string field, string text, int slop = 0)
Parameters
fieldstringA text field indexed with positions (all text fields created by SchemaBuilder are).
textstringThe phrase. A single word becomes a term query; text with no words matches nothing.
slopintHow many positions words may be moved in total and still match. 0 means the exact phrase;
"a b"with slop 1 matches"a x b", and swapping two words costs 2.