Пример #1
0
        public SpanWeight(SpanQuery query, Searcher searcher)
        {
            this.similarity    = query.GetSimilarity(searcher);
            this.internalQuery = query;

            terms = Lucene.Net.Support.Compatibility.SetFactory.GetSet <Term>();
            query.ExtractTerms(terms);

            idfExp = similarity.IdfExplain(terms, searcher);
            idf    = idfExp.Idf;
        }
Пример #2
0
		public SpanWeight(SpanQuery query, Searcher searcher)
		{
			this.similarity = query.GetSimilarity(searcher);
			this.internalQuery = query;

		    terms = Lucene.Net.Support.Compatibility.SetFactory.CreateHashSet<Term>();
			query.ExtractTerms(terms);

			idfExp = similarity.IdfExplain(terms, searcher);
			idf = idfExp.Idf;
		}