Esempio n. 1
0
 /// <param name="query">
 /// a Lucene query (ideally rewritten using <see cref="Query.Rewrite(IndexReader)"/> before
 /// being passed to this class and the searcher)
 /// </param>
 /// <param name="fieldName">the Field name which is used to match Query terms</param>
 public QueryTermScorer(Query query, string fieldName)
     : this(QueryTermExtractor.GetTerms(query, false, fieldName))
 {
 }
Esempio n. 2
0
 /// <param name="query">
 /// a Lucene query (ideally rewritten using <see cref="Query.Rewrite(IndexReader)"/> before
 /// being passed to this class and the searcher)
 /// </param>
 /// <param name="reader">
 /// used to compute IDF which can be used to a) score selected
 /// fragments better b) use graded highlights eg set font color
 /// intensity
 /// </param>
 /// <param name="fieldName">
 /// the field on which Inverse Document Frequency (IDF)
 /// calculations are based
 /// </param>
 public QueryTermScorer(Query query, IndexReader reader, string fieldName)
     : this(QueryTermExtractor.GetIdfWeightedTerms(query, reader, fieldName))
 {
 }
Esempio n. 3
0
 /// <param name="query">
 /// a Lucene query (ideally rewritten using <see cref="Query.Rewrite(IndexReader)"/> before
 /// being passed to this class and the searcher)
 /// </param>
 public QueryTermScorer(Query query)
     : this(QueryTermExtractor.GetTerms(query))
 {
 }