Adds a term to the end of the query phrase. The relative position of the term within the phrase is specified explicitly. This allows e.g. phrases with more than one term at the same position or phrases with gaps (e.g. in connection with stopwords).

Namespace: Lucene.Net.Search
Assembly: Lucene.Net (in Lucene.Net.dll) Version: 2.9.4.1

Syntax

C#
public virtual void Add(
	Term term,
	int position
)
Visual Basic
Public Overridable Sub Add ( _
	term As Term, _
	position As Integer _
)
Visual C++
public:
virtual void Add(
	Term^ term, 
	int position
)

Parameters

term
Type: Lucene.Net.Index..::..Term

[Missing <param name="term"/> documentation for "M:Lucene.Net.Search.PhraseQuery.Add(Lucene.Net.Index.Term,System.Int32)"]

position
Type: System..::..Int32

[Missing <param name="position"/> documentation for "M:Lucene.Net.Search.PhraseQuery.Add(Lucene.Net.Index.Term,System.Int32)"]

See Also