You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucenenet.apache.org by ni...@apache.org on 2017/01/25 03:44:28 UTC

[44/50] [abbrv] lucenenet git commit: Lucene.Net.Analysis.Common.Analysis.Util.AbstractAnalysisFactory: commented code in AssureMatchVersion() because luceneMatchVersion can never be null in .NET

Lucene.Net.Analysis.Common.Analysis.Util.AbstractAnalysisFactory: commented code in AssureMatchVersion() because luceneMatchVersion can never be null in .NET


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

Branch: refs/heads/api-work
Commit: eee04c44226262b6c795cb525006450022f36d5e
Parents: 84c5f09
Author: Shad Storhaug <sh...@shadstorhaug.com>
Authored: Wed Jan 25 07:47:17 2017 +0700
Committer: Shad Storhaug <sh...@shadstorhaug.com>
Committed: Wed Jan 25 09:34:49 2017 +0700

----------------------------------------------------------------------
 .../Analysis/Util/AbstractAnalysisFactory.cs             | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucenenet/blob/eee04c44/src/Lucene.Net.Analysis.Common/Analysis/Util/AbstractAnalysisFactory.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Analysis.Common/Analysis/Util/AbstractAnalysisFactory.cs b/src/Lucene.Net.Analysis.Common/Analysis/Util/AbstractAnalysisFactory.cs
index 9871646..d123f37 100644
--- a/src/Lucene.Net.Analysis.Common/Analysis/Util/AbstractAnalysisFactory.cs
+++ b/src/Lucene.Net.Analysis.Common/Analysis/Util/AbstractAnalysisFactory.cs
@@ -81,10 +81,13 @@ namespace Lucene.Net.Analysis.Util
         /// </summary>
         protected internal void AssureMatchVersion()
         {
-            if (luceneMatchVersion == null)
-            {
-                throw new System.ArgumentException("Configuration Error: Factory '" + this.GetType().FullName + "' needs a 'luceneMatchVersion' parameter");
-            }
+            // LUCENENET NOTE: since luceneMatchVersion can never be null in .NET,
+            // this method effectively does nothing. However, leaving it in place because
+            // it is used throughout Lucene.
+            //if (luceneMatchVersion == null)
+            //{
+            //    throw new System.ArgumentException("Configuration Error: Factory '" + this.GetType().FullName + "' needs a 'luceneMatchVersion' parameter");
+            //}
         }
 
         public LuceneVersion LuceneMatchVersion