lucenenet-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nightowl...@apache.org
Subject [48/62] [abbrv] lucenenet git commit: Lucene.Net.Core.Index: Deleted obsolete files that are no longer in use
Date Sat, 01 Apr 2017 01:09:41 GMT
http://git-wip-us.apache.org/repos/asf/lucenenet/blob/228b970a/src/Lucene.Net.Core/Index/TermsHashPerThread.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Core/Index/TermsHashPerThread.cs b/src/Lucene.Net.Core/Index/TermsHashPerThread.cs
deleted file mode 100644
index 9b16d34..0000000
--- a/src/Lucene.Net.Core/Index/TermsHashPerThread.cs
+++ /dev/null
@@ -1,140 +0,0 @@
-/* 
- * Licensed to the Apache Software Foundation (ASF) under one or more
- * contributor license agreements.  See the NOTICE file distributed with
- * this work for additional information regarding copyright ownership.
- * The ASF licenses this file to You under the Apache License, Version 2.0
- * (the "License"); you may not use this file except in compliance with
- * the License.  You may obtain a copy of the License at
- * 
- * http://www.apache.org/licenses/LICENSE-2.0
- * 
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-using System;
-
-namespace Lucene.Net.Index
-{
-    
-    sealed class TermsHashPerThread:InvertedDocConsumerPerThread
-    {
-        
-        internal TermsHash termsHash;
-        internal TermsHashConsumerPerThread consumer;
-        internal TermsHashPerThread nextPerThread;
-        
-        internal CharBlockPool charPool;
-        internal IntBlockPool intPool;
-        internal ByteBlockPool bytePool;
-        internal bool primary;
-        internal DocumentsWriter.DocState docState;
-        
-        internal RawPostingList[] freePostings = new RawPostingList[256];
-        internal int freePostingsCount;
-        
-        public TermsHashPerThread(DocInverterPerThread docInverterPerThread, TermsHash termsHash,
TermsHash nextTermsHash, TermsHashPerThread primaryPerThread)
-        {
-            docState = docInverterPerThread.docState;
-            
-            this.termsHash = termsHash;
-            this.consumer = termsHash.consumer.AddThread(this);
-            
-            if (nextTermsHash != null)
-            {
-                // We are primary
-                charPool = new CharBlockPool(termsHash.docWriter);
-                primary = true;
-            }
-            else
-            {
-                charPool = primaryPerThread.charPool;
-                primary = false;
-            }
-            
-            intPool = new IntBlockPool(termsHash.docWriter, termsHash.trackAllocations);
-            bytePool = new ByteBlockPool(termsHash.docWriter.byteBlockAllocator, termsHash.trackAllocations);
-            
-            if (nextTermsHash != null)
-                nextPerThread = nextTermsHash.AddThread(docInverterPerThread, this);
-            else
-                nextPerThread = null;
-        }
-        
-        internal override InvertedDocConsumerPerField AddField(DocInverterPerField docInverterPerField,
FieldInfo fieldInfo)
-        {
-            return new TermsHashPerField(docInverterPerField, this, nextPerThread, fieldInfo);
-        }
-        
-        public override void  Abort()
-        {
-            lock (this)
-            {
-                Reset(true);
-                consumer.Abort();
-                if (nextPerThread != null)
-                    nextPerThread.Abort();
-            }
-        }
-        
-        // perField calls this when it needs more postings:
-        internal void  MorePostings()
-        {
-            System.Diagnostics.Debug.Assert(freePostingsCount == 0);
-            termsHash.GetPostings(freePostings);
-            freePostingsCount = freePostings.Length;
-            System.Diagnostics.Debug.Assert(noNullPostings(freePostings, freePostingsCount,
"consumer=" + consumer));
-        }
-        
-        private static bool noNullPostings(RawPostingList[] postings, int count, System.String
details)
-        {
-            for (int i = 0; i < count; i++)
-                System.Diagnostics.Debug.Assert(postings[i] != null, "postings[" + i + "]
of " + count + " is null: " + details);
-            return true;
-        }
-        
-        public override void  StartDocument()
-        {
-            consumer.StartDocument();
-            if (nextPerThread != null)
-                nextPerThread.consumer.StartDocument();
-        }
-        
-        public override DocumentsWriter.DocWriter FinishDocument()
-        {
-            DocumentsWriter.DocWriter doc = consumer.FinishDocument();
-            
-            DocumentsWriter.DocWriter doc2;
-            if (nextPerThread != null)
-                doc2 = nextPerThread.consumer.FinishDocument();
-            else
-                doc2 = null;
-            if (doc == null)
-                return doc2;
-            else
-            {
-                doc.SetNext(doc2);
-                return doc;
-            }
-        }
-        
-        // Clear all state
-        internal void  Reset(bool recyclePostings)
-        {
-            intPool.Reset();
-            bytePool.Reset();
-            
-            if (primary)
-                charPool.Reset();
-            
-            if (recyclePostings)
-            {
-                termsHash.RecyclePostings(freePostings, freePostingsCount);
-                freePostingsCount = 0;
-            }
-        }
-    }
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/228b970a/src/Lucene.Net.Core/project.json
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Core/project.json b/src/Lucene.Net.Core/project.json
index cd8e1a3..e194273 100644
--- a/src/Lucene.Net.Core/project.json
+++ b/src/Lucene.Net.Core/project.json
@@ -14,17 +14,6 @@
         "define": [ "FEATURE_TASKMERGESCHEDULER", "NETSTANDARD" ],
         "compile": {
           "exclude": [
-            "Index/CompoundFile*.cs",
-            "Index/DefaultSkipList*.cs",
-            "Index/FormatPostings*.cs",
-            "Index/MultiLevelSkipList*.cs",
-            "Index/NormsWriter*.cs",
-            "Index/SegmentTerm*.cs",
-            "Index/StoredFieldsWriter*.cs",
-            "Index/TermInfo*.cs",
-            "Index/TermPosition*.cs",
-            "Index/TermVectorEntry*.cs",
-            "Index/TermVectorsTerms*.cs",
             "Search/Function/*",
             "Search/Grouping/*",
             "Search/Span*.cs",
@@ -32,55 +21,7 @@
           ],
           "excludeFiles": [
             "RectangularArrays.cs",
-            "Index/AbstractAllTermDocs.cs",
-            "Index/AllTermDocs.cs",
-            "Index/BufferedDeletes.cs",
-            "Index/ByteBlockPool.cs",
-            "Index/CharBlockPool.cs",
             "Index/ConcurrentMergeScheduler.cs",
-            "Index/DocConsumerPerThread.cs",
-            "Index/DocFieldConsumerPerThread.cs",
-            "Index/DocFieldConsumers.cs",
-            "Index/DocFieldConsumersPerField.cs",
-            "Index/DocFieldConsumersPerThread.cs",
-            "Index/DocFieldProcessorPerThread.cs",
-            "Index/DocInverterPerThread.cs",
-            "Index/DocumentsWriterThreadState.cs",
-            "Index/FieldReaderException.cs",
-            "Index/FieldSortedTermVectorMapper.cs",
-            "Index/FieldsReader.cs",
-            "Index/FieldsWriter.cs",
-            "Index/FilterIndexReader.cs",
-            "Index/FilteredIndexReader.cs",
-            "Index/FreqProxFieldMergeState.cs",
-            "Index/FreqProxTermsWriterPerThread.cs",
-            "Index/IndexFileNameFilter.cs",
-            "Index/IntBlockPool.cs",
-            "Index/InvertedDocConsumerPerThread.cs",
-            "Index/InvertedDocEndConsumerPerThread.cs",
-            "Index/MergeDocIDRemapper.cs",
-            "Index/MultipleTermPositions.cs",
-            "Index/ParallelReader.cs",
-            "Index/Payload.cs",
-            "Index/PositionBasedTermVectorMapper.cs",
-            "Index/RawPostingList.cs",
-            "Index/ReadOnlyDirectoryReader.cs",
-            "Index/ReadOnlySegmentReader.cs",
-            "Index/ReusableStringReader.cs",
-            "Index/SegmentMergeInfo.cs",
-            "Index/SegmentMergeQueue.cs",
-            "Index/SortedTermVectorMapper.cs",
-            "Index/StaleReaderException.cs",
-            "Index/TermBuffer.cs",
-            "Index/TermDocs.cs",
-            "Index/TermEnum.cs",
-            "Index/TermFreqVector.cs",
-            "Index/TermsHashConsumerPerThread.cs",
-            "Index/TermsHashPerThread.cs",
-            "Index/TermVectorMapper.cs",
-            "Index/TermVectorOffsetInfo.cs",
-            "Index/TermVectorsReader.cs",
-            "Index/TermVectorsWriter.cs",
             "Search/CachingSpanFilter.cs",
             "Search/DefaultSimilarity.cs",
             "Search/FieldDocSortedHitQueue.cs",
@@ -147,17 +88,6 @@
         ],
         "compile": {
           "exclude": [
-            "Index/CompoundFile*.cs",
-            "Index/DefaultSkipList*.cs",
-            "Index/FormatPostings*.cs",
-            "Index/MultiLevelSkipList*.cs",
-            "Index/NormsWriter*.cs",
-            "Index/SegmentTerm*.cs",
-            "Index/StoredFieldsWriter*.cs",
-            "Index/TermInfo*.cs",
-            "Index/TermPosition*.cs",
-            "Index/TermVectorEntry*.cs",
-            "Index/TermVectorsTerms*.cs",
             "Search/Function/*",
             "Search/Grouping/*",
             "Search/Span*.cs",
@@ -165,54 +95,6 @@
           ],
           "excludeFiles": [
             "RectangularArrays.cs",
-            "Index/AbstractAllTermDocs.cs",
-            "Index/AllTermDocs.cs",
-            "Index/BufferedDeletes.cs",
-            "Index/ByteBlockPool.cs",
-            "Index/CharBlockPool.cs",
-            "Index/DocConsumerPerThread.cs",
-            "Index/DocFieldConsumerPerThread.cs",
-            "Index/DocFieldConsumers.cs",
-            "Index/DocFieldConsumersPerField.cs",
-            "Index/DocFieldConsumersPerThread.cs",
-            "Index/DocFieldProcessorPerThread.cs",
-            "Index/DocInverterPerThread.cs",
-            "Index/DocumentsWriterThreadState.cs",
-            "Index/FieldReaderException.cs",
-            "Index/FieldSortedTermVectorMapper.cs",
-            "Index/FieldsReader.cs",
-            "Index/FieldsWriter.cs",
-            "Index/FilterIndexReader.cs",
-            "Index/FilteredIndexReader.cs",
-            "Index/FreqProxFieldMergeState.cs",
-            "Index/FreqProxTermsWriterPerThread.cs",
-            "Index/IndexFileNameFilter.cs",
-            "Index/IntBlockPool.cs",
-            "Index/InvertedDocConsumerPerThread.cs",
-            "Index/InvertedDocEndConsumerPerThread.cs",
-            "Index/MergeDocIDRemapper.cs",
-            "Index/MultipleTermPositions.cs",
-            "Index/ParallelReader.cs",
-            "Index/Payload.cs",
-            "Index/PositionBasedTermVectorMapper.cs",
-            "Index/RawPostingList.cs",
-            "Index/ReadOnlyDirectoryReader.cs",
-            "Index/ReadOnlySegmentReader.cs",
-            "Index/ReusableStringReader.cs",
-            "Index/SegmentMergeInfo.cs",
-            "Index/SegmentMergeQueue.cs",
-            "Index/SortedTermVectorMapper.cs",
-            "Index/StaleReaderException.cs",
-            "Index/TermBuffer.cs",
-            "Index/TermDocs.cs",
-            "Index/TermEnum.cs",
-            "Index/TermFreqVector.cs",
-            "Index/TermsHashConsumerPerThread.cs",
-            "Index/TermsHashPerThread.cs",
-            "Index/TermVectorMapper.cs",
-            "Index/TermVectorOffsetInfo.cs",
-            "Index/TermVectorsReader.cs",
-            "Index/TermVectorsWriter.cs",
             "Search/CachingSpanFilter.cs",
             "Search/DefaultSimilarity.cs",
             "Search/FieldDocSortedHitQueue.cs",


Mime
View raw message