Searched refs:pq (Results 1 - 25 of 49) sorted by relevance

12

/lucene-3.6.0/lucene/core/src/test/org/apache/lucene/util/
H A DTestPriorityQueue.java41 PriorityQueue<Integer> pq = new IntegerQueue(count);
48 pq.add(next);
61 Integer next = pq.pop();
75 PriorityQueue<Integer> pq = new IntegerQueue(3);
76 pq.add(2);
77 pq.add(3);
78 pq.add(1);
79 assertEquals(3, pq.size());
80 pq.clear();
81 assertEquals(0, pq
[all...]
/lucene-3.6.0/lucene/backwards/src/test/org/apache/lucene/util/
H A DTestPriorityQueue.java41 PriorityQueue<Integer> pq = new IntegerQueue(count);
48 pq.add(next);
61 Integer next = pq.pop();
75 PriorityQueue<Integer> pq = new IntegerQueue(3);
76 pq.add(2);
77 pq.add(3);
78 pq.add(1);
79 assertEquals(3, pq.size());
80 pq.clear();
81 assertEquals(0, pq
[all...]
/lucene-3.6.0/lucene/core/src/java/org/apache/lucene/search/
H A DTopDocsCollector.java46 protected PriorityQueue<T> pq; field in class:TopDocsCollector
51 protected TopDocsCollector(PriorityQueue<T> pq) { argument
52 this.pq = pq;
61 results[i] = pq.pop();
82 // In case pq was populated with sentinel values, there might be less
83 // results than pq.size(). Therefore return all results until either
84 // pq.size() or totalHits.
85 return totalHits < pq.size() ? totalHits : pq
[all...]
H A DTopScoreDocCollector.java62 pqTop = pq.updateTop();
107 pqTop = pq.updateTop();
123 return collectedHits < pq.size() ? collectedHits : pq.size();
157 pqTop = pq.updateTop();
202 pqTop = pq.updateTop();
218 return collectedHits < pq.size() ? collectedHits : pq.size();
278 pqTop = pq.top();
295 for (int i = pq
[all...]
H A DSloppyPhraseScorer.java35 private final PhraseQueue pq; // for advancing min position field in class:SloppyPhraseScorer
50 pq = new PhraseQueue(postings.length);
77 PhrasePositions pp = pq.pop();
79 int next = pq.top().position;
88 pq.add(pp);
89 pp = pq.pop();
90 next = pq.top().position;
140 PhrasePositions pp2 = pq.pop();
148 pq.add(rptStack[i]);
205 pq
[all...]
H A DTopFieldCollector.java62 bottom = pq.updateTop();
168 bottom = pq.updateTop();
284 bottom = pq.updateTop();
395 bottom = pq.updateTop();
549 bottom = pq.updateTop();
699 bottom = pq.updateTop();
862 private TopFieldCollector(PriorityQueue<Entry> pq, int numHits, boolean fillFields) { argument
863 super(pq);
958 bottom = pq.add(new Entry(slot, docBase + doc, score));
971 FieldValueHitQueue<Entry> queue = (FieldValueHitQueue<Entry>) pq;
[all...]
/lucene-3.6.0/lucene/core/src/test/org/apache/lucene/search/
H A DTestSloppyPhraseQuery.java179 private void assertSaneScoring(PhraseQuery pq, IndexSearcher searcher) throws Exception { argument
180 searcher.search(pq, new Collector() {
205 QueryUtils.check(random, pq, searcher);
227 PhraseQuery pq = new PhraseQuery();
229 pq.add(new Term("lyrics", "drug"), 1);
230 pq.add(new Term("lyrics", "drug"), 4);
231 pq.setSlop(0);
232 assertEquals(0, is.search(pq, 4).totalHits);
233 pq.setSlop(1);
234 assertEquals(3, is.search(pq,
[all...]
H A DTestSimilarity.java130 PhraseQuery pq = new PhraseQuery();
131 pq.add(a);
132 pq.add(c);
133 //System.out.println(pq.toString("field"));
134 searcher.search(pq,
154 pq.setSlop(2);
155 //System.out.println(pq.toString("field"));
156 searcher.search(pq, new Collector() {
H A DTestTopDocsCollector.java49 for (int i = pq.size(); i > 1; i--) { pq.pop(); }
50 maxScore = pq.pop().score;
59 pq.insertWithOverflow(new ScoreDoc(doc + base, scores[idx++]));
134 // start > pq.size()
137 // start == pq.size()
H A DTestSloppyPhraseQuery2.java190 MultiPhraseQuery pq = new MultiPhraseQuery();
198 pq.add(terms, position);
201 return pq;
H A DTestBooleanQuery.java99 PhraseQuery pq = new PhraseQuery();
100 q.add(pq, BooleanClause.Occur.SHOULD);
106 pq = new PhraseQuery();
108 q.add(pq, BooleanClause.Occur.MUST);
113 dmq.add(pq);
H A DTestMultiPhraseQuery.java560 final PhraseQuery pq = new PhraseQuery();
562 pq.add(new Term("field",tap.token), tap.pos);
564 doTestZeroPosIncrSloppy(pq, 0);
565 pq.setSlop(1);
566 doTestZeroPosIncrSloppy(pq, 0);
567 pq.setSlop(2);
568 doTestZeroPosIncrSloppy(pq, 1);
/lucene-3.6.0/lucene/backwards/src/test/org/apache/lucene/search/
H A DTestSloppyPhraseQuery.java179 private void assertSaneScoring(PhraseQuery pq, IndexSearcher searcher) throws Exception { argument
180 searcher.search(pq, new Collector() {
205 QueryUtils.check(random, pq, searcher);
227 PhraseQuery pq = new PhraseQuery();
229 pq.add(new Term("lyrics", "drug"), 1);
230 pq.add(new Term("lyrics", "drug"), 4);
231 pq.setSlop(0);
232 assertEquals(0, is.search(pq, 4).totalHits);
233 pq.setSlop(1);
234 assertEquals(3, is.search(pq,
[all...]
H A DTestSimilarity.java130 PhraseQuery pq = new PhraseQuery();
131 pq.add(a);
132 pq.add(c);
133 //System.out.println(pq.toString("field"));
134 searcher.search(pq,
154 pq.setSlop(2);
155 //System.out.println(pq.toString("field"));
156 searcher.search(pq, new Collector() {
H A DTestTopDocsCollector.java49 for (int i = pq.size(); i > 1; i--) { pq.pop(); }
50 maxScore = pq.pop().score;
59 pq.insertWithOverflow(new ScoreDoc(doc + base, scores[idx++]));
134 // start > pq.size()
137 // start == pq.size()
H A DTestBooleanQuery.java99 PhraseQuery pq = new PhraseQuery();
100 q.add(pq, BooleanClause.Occur.SHOULD);
106 pq = new PhraseQuery();
108 q.add(pq, BooleanClause.Occur.MUST);
113 dmq.add(pq);
/lucene-3.6.0/lucene/contrib/highlighter/src/java/org/apache/lucene/search/vectorhighlight/
H A DFieldQuery.java77 PhraseQuery pq = (PhraseQuery)flatQuery;
78 if( pq.getTerms().length > 1 ){
79 for( Term term : pq.getTerms() )
119 PhraseQuery pq = (PhraseQuery)sourceQuery;
120 if( pq.getTerms().length > 1 )
121 flatQueries.add( pq );
122 else if( pq.getTerms().length == 1 ){
123 flatQueries.add( new TermQuery( pq.getTerms()[0] ) );
198 PhraseQuery pq = new PhraseQuery();
200 pq
[all...]
/lucene-3.6.0/lucene/contrib/benchmark/src/java/org/apache/lucene/benchmark/quality/utils/
H A DQualityQueriesFinder.java87 PriorityQueue<TermDf> pq = new TermsDfQueue(numTerms);
99 pq.insertWithOverflow(new TermDf(ttxt,df));
105 String res[] = new String[pq.size()];
107 while (pq.size()>0) {
108 TermDf tdf = pq.pop();
/lucene-3.6.0/lucene/core/src/test/org/apache/lucene/index/
H A DTestLazyProxSkipping.java105 PhraseQuery pq = new PhraseQuery();
106 pq.add(new Term(this.field, this.term1));
107 pq.add(new Term(this.field, this.term2));
108 return this.searcher.search(pq, null, 1000).scoreDocs;
/lucene-3.6.0/lucene/backwards/src/test/org/apache/lucene/index/
H A DTestLazyProxSkipping.java105 PhraseQuery pq = new PhraseQuery();
106 pq.add(new Term(this.field, this.term1));
107 pq.add(new Term(this.field, this.term2));
108 return this.searcher.search(pq, null, 1000).scoreDocs;
H A DTestIndexWriterExceptions.java1005 PhraseQuery pq = new PhraseQuery();
1006 pq.add(new Term("content", "silly"));
1007 pq.add(new Term("content", "content"));
1008 assertEquals(0, s.search(pq, 1).totalHits);
1010 pq = new PhraseQuery();
1011 pq.add(new Term("content", "good"));
1012 pq.add(new Term("content", "content"));
1013 assertEquals(numDocs1+numDocs2, s.search(pq, 1).totalHits);
1085 PhraseQuery pq = new PhraseQuery();
1086 pq
[all...]
/lucene-3.6.0/solr/core/src/java/org/apache/solr/schema/
H A DTextField.java314 // PhraseQuery pq = newPhraseQuery();
315 PhraseQuery pq = new PhraseQuery();
316 pq.setSlop(phraseSlop);
337 pq.add(new Term(field, term),position);
339 pq.add(new Term(field, term));
342 return pq;
/lucene-3.6.0/lucene/contrib/highlighter/src/test/org/apache/lucene/search/vectorhighlight/
H A DAbstractTestCase.java135 return pq( boost, slop, F, texts );
138 protected Query pq( String field, String... texts ){ method in class:AbstractTestCase
139 return pq( 1F, 0, field, texts );
142 protected Query pq( float boost, String field, String... texts ){ method in class:AbstractTestCase
143 return pq( boost, 0, field, texts );
146 protected Query pq( float boost, int slop, String field, String... texts ){ method in class:AbstractTestCase
/lucene-3.6.0/lucene/contrib/facet/src/java/org/apache/lucene/facet/search/sampling/
H A DRepeatableSampler.java276 IntPriorityQueue pq = new IntPriorityQueue(sampleSize);
283 pq.insertWithReuse((int)(it.getDocID() * PHI_32) & 0x7FFFFFFF);
291 Object[] heap = pq.getHeap();
/lucene-3.6.0/lucene/contrib/queryparser/src/java/org/apache/lucene/queryParser/standard/processors/
H A DAnalyzerQueryNodeProcessor.java278 TokenizedPhraseQueryNode pq = new TokenizedPhraseQueryNode();
309 pq.add(newFieldNode);
313 return pq;

Completed in 175 milliseconds

12