Lucene.Net.Search.TestScoreCachingWrappingScorer.TestGetScores C# (CSharp) Метод

TestGetScores() приватный Метод

private TestGetScores ( ) : void
Результат void
		public virtual void  TestGetScores()
		{
			
			Scorer s = new SimpleScorer();
			ScoreCachingCollector scc = new ScoreCachingCollector(scores.Length);
			scc.SetScorer(s);
			
			// We need to iterate on the scorer so that its doc() advances.
			int doc;
			while ((doc = s.NextDoc()) != DocIdSetIterator.NO_MORE_DOCS)
			{
				scc.Collect(doc);
			}
			
			for (int i = 0; i < scores.Length; i++)
			{
				Assert.AreEqual(scores[i], scc.mscores[i], 0f);
			}
		}
	}
TestScoreCachingWrappingScorer