lucenenet-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From synhers...@apache.org
Subject [1/5] lucenenet git commit: Various fixes
Date Fri, 07 Nov 2014 03:59:48 GMT
Repository: lucenenet
Updated Branches:
  refs/heads/master b5afe7645 -> e07d11372


Various fixes


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

Branch: refs/heads/master
Commit: bf7317d282aba8093d56b646b1e622b4ed19e7d5
Parents: b5afe76
Author: Itamar Syn-Hershko <itamar@code972.com>
Authored: Wed Nov 5 20:10:13 2014 +0200
Committer: Itamar Syn-Hershko <itamar@code972.com>
Committed: Wed Nov 5 20:10:13 2014 +0200

----------------------------------------------------------------------
 src/Lucene.Net.Queries/Function/ValueSource.cs               | 6 +++---
 .../Function/ValueSources/ConstNumberSource.cs               | 2 +-
 .../Function/ValueSources/ConstValueSource.cs                | 8 --------
 .../Function/ValueSources/DoubleConstValueSource.cs          | 8 --------
 .../Function/ValueSources/OrdFieldSource.cs                  | 4 ++--
 .../Function/ValueSources/SimpleBoolFunction.cs              | 2 +-
 6 files changed, 7 insertions(+), 23 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucenenet/blob/bf7317d2/src/Lucene.Net.Queries/Function/ValueSource.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Queries/Function/ValueSource.cs b/src/Lucene.Net.Queries/Function/ValueSource.cs
index 0f8ed03..ccfdc59 100644
--- a/src/Lucene.Net.Queries/Function/ValueSource.cs
+++ b/src/Lucene.Net.Queries/Function/ValueSource.cs
@@ -123,7 +123,7 @@ namespace Lucene.Net.Queries.Function
                 this.context = context;
             }
 
-            public override FieldComparator<double?> NewComparator(string fieldname,
int numHits, int sortPos, bool reversed)
+            public override FieldComparator NewComparator(string fieldname, int numHits,
int sortPos, bool reversed)
             {
                 return new ValueSourceComparator(outerInstance, context, numHits);
             }
@@ -180,7 +180,7 @@ namespace Lucene.Net.Queries.Function
                 }
             }
 
-            public override double? TopValue
+            public override object TopValue
             {
                 set
                 {
@@ -188,7 +188,7 @@ namespace Lucene.Net.Queries.Function
                 }
             }
 
-            public override double? Value(int slot)
+            public override IComparable Value(int slot)
             {
                 return values[slot];
             }

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/bf7317d2/src/Lucene.Net.Queries/Function/ValueSources/ConstNumberSource.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Queries/Function/ValueSources/ConstNumberSource.cs b/src/Lucene.Net.Queries/Function/ValueSources/ConstNumberSource.cs
index d208c92..2f30fc6 100644
--- a/src/Lucene.Net.Queries/Function/ValueSources/ConstNumberSource.cs
+++ b/src/Lucene.Net.Queries/Function/ValueSources/ConstNumberSource.cs
@@ -29,7 +29,7 @@ namespace Lucene.Net.Queries.Function.ValueSources
         public abstract long Long { get; }
         public abstract float Float { get; }
         public abstract double Double { get; }
-        public abstract Number Number { get; }
+        //public abstract Number Number { get; }
         public abstract bool Bool { get; }
     }
 }
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/bf7317d2/src/Lucene.Net.Queries/Function/ValueSources/ConstValueSource.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Queries/Function/ValueSources/ConstValueSource.cs b/src/Lucene.Net.Queries/Function/ValueSources/ConstValueSource.cs
index e27c869..adc2bf0 100644
--- a/src/Lucene.Net.Queries/Function/ValueSources/ConstValueSource.cs
+++ b/src/Lucene.Net.Queries/Function/ValueSources/ConstValueSource.cs
@@ -132,14 +132,6 @@ namespace Lucene.Net.Queries.Function.ValueSources
             }
         }
 
-        public override Number Number
-        {
-            get
-            {
-                return constant;
-            }
-        }
-
         public override bool Bool
         {
             get

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/bf7317d2/src/Lucene.Net.Queries/Function/ValueSources/DoubleConstValueSource.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Queries/Function/ValueSources/DoubleConstValueSource.cs b/src/Lucene.Net.Queries/Function/ValueSources/DoubleConstValueSource.cs
index 6e468ec..52cb8ca 100644
--- a/src/Lucene.Net.Queries/Function/ValueSources/DoubleConstValueSource.cs
+++ b/src/Lucene.Net.Queries/Function/ValueSources/DoubleConstValueSource.cs
@@ -141,14 +141,6 @@ namespace Lucene.Net.Queries.Function.ValueSources
             }
         }
 
-        public override Number Number
-        {
-            get
-            {
-                return constant;
-            }
-        }
-
         public override bool Bool
         {
             get

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/bf7317d2/src/Lucene.Net.Queries/Function/ValueSources/OrdFieldSource.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Queries/Function/ValueSources/OrdFieldSource.cs b/src/Lucene.Net.Queries/Function/ValueSources/OrdFieldSource.cs
index 93eecab..e229479 100644
--- a/src/Lucene.Net.Queries/Function/ValueSources/OrdFieldSource.cs
+++ b/src/Lucene.Net.Queries/Function/ValueSources/OrdFieldSource.cs
@@ -66,7 +66,7 @@ namespace Lucene.Net.Queries.Function.ValueSources
             return new IntDocValuesAnonymousInnerClassHelper(this, this, off, sindex);
         }
 
-        private class IntDocValuesAnonymousInnerClassHelper : IntDocValues
+        private sealed class IntDocValuesAnonymousInnerClassHelper : IntDocValues
         {
             private readonly OrdFieldSource outerInstance;
 
@@ -81,7 +81,7 @@ namespace Lucene.Net.Queries.Function.ValueSources
                 this.sindex = sindex;
             }
 
-            protected virtual string ToTerm(string readableValue)
+            private string ToTerm(string readableValue)
             {
                 return readableValue;
             }

http://git-wip-us.apache.org/repos/asf/lucenenet/blob/bf7317d2/src/Lucene.Net.Queries/Function/ValueSources/SimpleBoolFunction.cs
----------------------------------------------------------------------
diff --git a/src/Lucene.Net.Queries/Function/ValueSources/SimpleBoolFunction.cs b/src/Lucene.Net.Queries/Function/ValueSources/SimpleBoolFunction.cs
index eab3ac6..3e59f6e 100644
--- a/src/Lucene.Net.Queries/Function/ValueSources/SimpleBoolFunction.cs
+++ b/src/Lucene.Net.Queries/Function/ValueSources/SimpleBoolFunction.cs
@@ -51,7 +51,7 @@ namespace Lucene.Net.Queries.Function.ValueSources
         {
             private readonly SimpleBoolFunction outerInstance;
 
-            private FunctionValues vals;
+            private readonly FunctionValues vals;
 
             public BoolDocValuesAnonymousInnerClassHelper(SimpleBoolFunction outerInstance,
SimpleBoolFunction @this, FunctionValues vals)
                 : base(@this)


Mime
View raw message