From 11fb1314e6f932ad2aaf913c8462caef103a1f7b Mon Sep 17 00:00:00 2001 From: Michael Busch Date: Sun, 11 Mar 2007 20:29:19 +0000 Subject: [PATCH] Corrected comments and changed a variable name in SegmentTermPositions to better reflect the meaning of the variable git-svn-id: https://svn.apache.org/repos/asf/lucene/java/trunk@517007 13f79535-47bb-0310-9956-ffa450edef68 --- .../lucene/index/SegmentTermPositions.java | 22 +++++++++---------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/src/java/org/apache/lucene/index/SegmentTermPositions.java b/src/java/org/apache/lucene/index/SegmentTermPositions.java index b5d9f7e2368..6ca24940793 100644 --- a/src/java/org/apache/lucene/index/SegmentTermPositions.java +++ b/src/java/org/apache/lucene/index/SegmentTermPositions.java @@ -30,7 +30,7 @@ extends SegmentTermDocs implements TermPositions { // these variables are being used to remember information // for a lazy skip private long lazySkipPointer = 0; - private int lazySkipDocCount = 0; + private int lazySkipProxCount = 0; SegmentTermPositions(SegmentReader p) { super(p); @@ -42,7 +42,7 @@ extends SegmentTermDocs implements TermPositions { if (ti != null) lazySkipPointer = ti.proxPointer; - lazySkipDocCount = 0; + lazySkipProxCount = 0; proxCount = 0; } @@ -59,14 +59,14 @@ extends SegmentTermDocs implements TermPositions { } protected final void skippingDoc() throws IOException { - // we remember to skip the remaining positions of the current - // document lazily - lazySkipDocCount += freq; + // we remember to skip a document lazily + lazySkipProxCount += freq; } public final boolean next() throws IOException { - // we remember to skip a document lazily - lazySkipDocCount += proxCount; + // we remember to skip the remaining positions of the current + // document lazily + lazySkipProxCount += proxCount; if (super.next()) { // run super proxCount = freq; // note frequency @@ -85,7 +85,7 @@ extends SegmentTermDocs implements TermPositions { protected void skipProx(long proxPointer) throws IOException { // we save the pointer, we might have to skip there lazily lazySkipPointer = proxPointer; - lazySkipDocCount = 0; + lazySkipProxCount = 0; proxCount = 0; } @@ -115,9 +115,9 @@ extends SegmentTermDocs implements TermPositions { lazySkipPointer = 0; } - if (lazySkipDocCount != 0) { - skipPositions(lazySkipDocCount); - lazySkipDocCount = 0; + if (lazySkipProxCount != 0) { + skipPositions(lazySkipProxCount); + lazySkipProxCount = 0; } }