lucenenet-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mhern...@apache.org
Subject [22/50] [abbrv] git commit: More cleanup
Date Tue, 24 Sep 2013 18:32:58 GMT
More cleanup


Project: http://git-wip-us.apache.org/repos/asf/lucenenet/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucenenet/commit/16ff6a7b
Tree: http://git-wip-us.apache.org/repos/asf/lucenenet/tree/16ff6a7b
Diff: http://git-wip-us.apache.org/repos/asf/lucenenet/diff/16ff6a7b

Branch: refs/heads/branch_4x
Commit: 16ff6a7b3c233554af33bbdbca18d24244982147
Parents: 80561f7
Author: Paul Irwin <paulirwin@gmail.com>
Authored: Tue Jul 23 20:24:13 2013 -0400
Committer: Paul Irwin <paulirwin@gmail.com>
Committed: Tue Jul 23 20:24:13 2013 -0400

----------------------------------------------------------------------
 src/core/Analysis/Analyzer.cs              | 2 +-
 src/core/Codecs/BlockTreeTermsWriter.cs    | 2 +-
 src/core/Index/BufferedDeletesStream.cs    | 8 ++++----
 src/core/Index/ConcurrentMergeScheduler.cs | 8 ++++----
 src/core/Search/BooleanQuery.cs            | 2 +-
 src/core/Search/CachingWrapperFilter.cs    | 2 +-
 src/core/Search/Scorer.cs                  | 2 +-
 src/core/Util/Packed/BlockPackedReader.cs  | 2 +-
 8 files changed, 14 insertions(+), 14 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucenenet/blob/16ff6a7b/src/core/Analysis/Analyzer.cs
----------------------------------------------------------------------
diff --git a/src/core/Analysis/Analyzer.cs b/src/core/Analysis/Analyzer.cs
index baeb583..a55cc54 100644
--- a/src/core/Analysis/Analyzer.cs
+++ b/src/core/Analysis/Analyzer.cs
@@ -159,7 +159,7 @@ namespace Lucene.Net.Analysis
 
             public virtual void SetReader(System.IO.TextReader reader)
             {
-                source.SetReader(reader);
+                source.Reader = reader;
             }
 
             public TokenStream TokenStream

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/16ff6a7b/src/core/Codecs/BlockTreeTermsWriter.cs
----------------------------------------------------------------------
diff --git a/src/core/Codecs/BlockTreeTermsWriter.cs b/src/core/Codecs/BlockTreeTermsWriter.cs
index 14d5444..778eef0 100644
--- a/src/core/Codecs/BlockTreeTermsWriter.cs
+++ b/src/core/Codecs/BlockTreeTermsWriter.cs
@@ -887,7 +887,7 @@ namespace Lucene.Net.Codecs
                 //assert stats.docFreq > 0;
                 //if (DEBUG) System.out.println("BTTW.finishTerm term=" + fieldInfo.name
+ ":" + toString(text) + " seg=" + segment + " df=" + stats.docFreq);
 
-                blockBuilder.Add(Util.ToIntsRef(text, scratchIntsRef), noOutputs.GetNoOutput());
+                blockBuilder.Add(Lucene.Net.Util.Fst.Util.ToIntsRef(text, scratchIntsRef),
noOutputs.GetNoOutput());
                 pending.Add(new PendingTerm(BytesRef.DeepCopyOf(text), stats));
                 parent.postingsWriter.FinishTerm(stats);
                 numTerms++;

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/16ff6a7b/src/core/Index/BufferedDeletesStream.cs
----------------------------------------------------------------------
diff --git a/src/core/Index/BufferedDeletesStream.cs b/src/core/Index/BufferedDeletesStream.cs
index 78b2c51..73a3440 100644
--- a/src/core/Index/BufferedDeletesStream.cs
+++ b/src/core/Index/BufferedDeletesStream.cs
@@ -223,7 +223,7 @@ namespace Lucene.Net.Index
                         // Don't delete by Term here; DocumentsWriterPerThread
                         // already did that on flush:
                         delCount += ApplyQueryDeletes(packet.Queries, rld, reader);
-                        int fullDelCount = rld.Info.DelCount + rld.GetPendingDeleteCount();
+                        int fullDelCount = rld.Info.DelCount + rld.PendingDeleteCount;
                         //assert fullDelCount <= rld.info.info.getDocCount();
                         segAllDeletes = fullDelCount == rld.Info.info.DocCount;
                     }
@@ -279,7 +279,7 @@ namespace Lucene.Net.Index
                         {
                             delCount += ApplyTermDeletes(coalescedDeletes.TermsEnumerable,
rld, reader);
                             delCount += ApplyQueryDeletes(coalescedDeletes.QueriesEnumerable,
rld, reader);
-                            int fullDelCount = rld.Info.DelCount + rld.GetPendingDeleteCount();
+                            int fullDelCount = rld.Info.DelCount + rld.PendingDeleteCount;
                             //assert fullDelCount <= rld.info.info.getDocCount();
                             segAllDeletes = fullDelCount == rld.Info.info.DocCount;
                         }
@@ -413,7 +413,7 @@ namespace Lucene.Net.Index
                 if (!term.Field.Equals(currentField))
                 {
                     //assert currentField == null || currentField.compareTo(term.field())
< 0;
-                    currentField = term.Field();
+                    currentField = term.Field;
                     Terms terms = fields.Terms(currentField);
                     if (terms != null)
                     {
@@ -485,7 +485,7 @@ namespace Lucene.Net.Index
         private static long ApplyQueryDeletes(IEnumerable<QueryAndLimit> queriesIter,
ReadersAndLiveDocs rld, SegmentReader reader)
         {
             long delCount = 0;
-            AtomicReaderContext readerContext = reader.Context;
+            AtomicReaderContext readerContext = (AtomicReaderContext)reader.Context;
             bool any = false;
             foreach (QueryAndLimit ent in queriesIter)
             {

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/16ff6a7b/src/core/Index/ConcurrentMergeScheduler.cs
----------------------------------------------------------------------
diff --git a/src/core/Index/ConcurrentMergeScheduler.cs b/src/core/Index/ConcurrentMergeScheduler.cs
index 34c2094..709e784 100644
--- a/src/core/Index/ConcurrentMergeScheduler.cs
+++ b/src/core/Index/ConcurrentMergeScheduler.cs
@@ -364,11 +364,11 @@ namespace Lucene.Net.Index
                     }
                     try
                     {
-                        Wait();
+                        Monitor.Wait(this);
                     }
-                    catch (ThreadInterruptedException ie)
+                    catch (ThreadInterruptedException)
                     {
-                        throw new ThreadInterruptedException(ie);
+                        throw;
                     }
                 }
 
@@ -380,7 +380,7 @@ namespace Lucene.Net.Index
                     }
                 }
 
-                MergePolicy.OneMerge merge = writer.GetNextMerge();
+                MergePolicy.OneMerge merge = writer.NextMerge;
                 if (merge == null)
                 {
                     if (Verbose())

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/16ff6a7b/src/core/Search/BooleanQuery.cs
----------------------------------------------------------------------
diff --git a/src/core/Search/BooleanQuery.cs b/src/core/Search/BooleanQuery.cs
index f2b74ae..3de7417 100644
--- a/src/core/Search/BooleanQuery.cs
+++ b/src/core/Search/BooleanQuery.cs
@@ -259,7 +259,7 @@ namespace Lucene.Net.Search
                     cIter.MoveNext();
                     Weight w = wIter.Current;
                     BooleanClause c = cIter.Current;
-                    if (w.Scorer(context, true, true, context.Reader.LiveDocs) == null)
+                    if (w.Scorer(context, true, true, ((AtomicReader)context.Reader).LiveDocs)
== null)
                     {
                         if (c.IsRequired)
                         {

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/16ff6a7b/src/core/Search/CachingWrapperFilter.cs
----------------------------------------------------------------------
diff --git a/src/core/Search/CachingWrapperFilter.cs b/src/core/Search/CachingWrapperFilter.cs
index d66b44f..e1ad7f9 100644
--- a/src/core/Search/CachingWrapperFilter.cs
+++ b/src/core/Search/CachingWrapperFilter.cs
@@ -83,7 +83,7 @@ namespace Lucene.Net.Search
 
         public override DocIdSet GetDocIdSet(AtomicReaderContext context, IBits acceptDocs)
         {
-            AtomicReader reader = context.Reader;
+            AtomicReader reader = (AtomicReader)context.Reader;
             Object key = reader.CoreCacheKey;
 
             DocIdSet docIdSet = cache[key];

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/16ff6a7b/src/core/Search/Scorer.cs
----------------------------------------------------------------------
diff --git a/src/core/Search/Scorer.cs b/src/core/Search/Scorer.cs
index 8e4e5cd..6e067c0 100644
--- a/src/core/Search/Scorer.cs
+++ b/src/core/Search/Scorer.cs
@@ -44,7 +44,7 @@ namespace Lucene.Net.Search
     public abstract class Scorer : DocsEnum
     {
         protected readonly Weight weight;
-        protected virtual Weight Weight { get { return weight; } }
+        protected internal virtual Weight Weight { get { return weight; } }
 
         /// <summary>Constructs a Scorer.</summary>
         /// <param name="similarity">The <c>Similarity</c> implementation
used by this scorer.

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/16ff6a7b/src/core/Util/Packed/BlockPackedReader.cs
----------------------------------------------------------------------
diff --git a/src/core/Util/Packed/BlockPackedReader.cs b/src/core/Util/Packed/BlockPackedReader.cs
index 446fc7d..05a840e 100644
--- a/src/core/Util/Packed/BlockPackedReader.cs
+++ b/src/core/Util/Packed/BlockPackedReader.cs
@@ -70,7 +70,7 @@ namespace Lucene.Net.Util.Packed
             //assert index >= 0 && index < valueCount;
             int block = (int)Number.URShift(index, blockShift);
             int idx = (int)(index & blockMask);
-            return (minValues == null ? 0 : minValues[block]) + subReaders[block].get(idx);
+            return (minValues == null ? 0 : minValues[block]) + subReaders[block].Get(idx);
         }
     }
 }


Mime
View raw message