You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by pt...@apache.org on 2018/10/17 09:40:35 UTC

ignite git commit: Fix ambiguity for Contains method retrieval

Repository: ignite
Updated Branches:
  refs/heads/ignite-9877 15158ffae -> 88dce6dd7


Fix ambiguity for Contains method retrieval


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

Branch: refs/heads/ignite-9877
Commit: 88dce6dd7f45ad9a0720ae7cb5c9d63885febeae
Parents: 15158ff
Author: Pavel Tupitsyn <pt...@apache.org>
Authored: Wed Oct 17 12:40:27 2018 +0300
Committer: Pavel Tupitsyn <pt...@apache.org>
Committed: Wed Oct 17 12:40:27 2018 +0300

----------------------------------------------------------------------
 .../dotnet/Apache.Ignite.Linq/Impl/MethodVisitor.cs       | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ignite/blob/88dce6dd/modules/platforms/dotnet/Apache.Ignite.Linq/Impl/MethodVisitor.cs
----------------------------------------------------------------------
diff --git a/modules/platforms/dotnet/Apache.Ignite.Linq/Impl/MethodVisitor.cs b/modules/platforms/dotnet/Apache.Ignite.Linq/Impl/MethodVisitor.cs
index 84bd98f..375c7a8 100644
--- a/modules/platforms/dotnet/Apache.Ignite.Linq/Impl/MethodVisitor.cs
+++ b/modules/platforms/dotnet/Apache.Ignite.Linq/Impl/MethodVisitor.cs
@@ -54,7 +54,7 @@ namespace Apache.Ignite.Linq.Impl
         {
             GetStringMethod("ToLower", new Type[0], GetFunc("lower")),
             GetStringMethod("ToUpper", new Type[0], GetFunc("upper")),
-            GetStringMethod("Contains", del: (e, v) => VisitSqlLike(e, v, "'%' || ? || '%'")),
+            GetStringMethod("Contains", new[] {typeof (string)}, (e, v) => VisitSqlLike(e, v, "'%' || ? || '%'")),
             GetStringMethod("StartsWith", new[] {typeof (string)}, (e, v) => VisitSqlLike(e, v, "? || '%'")),
             GetStringMethod("EndsWith", new[] {typeof (string)}, (e, v) => VisitSqlLike(e, v, "'%' || ?")),
             GetStringMethod("IndexOf", new[] {typeof (string)}, GetFunc("instr", -1)),
@@ -72,7 +72,7 @@ namespace Apache.Ignite.Linq.Impl
             GetStringMethod("PadRight", "rpad", typeof (int), typeof (char)),
 
             GetRegexMethod("Replace", "regexp_replace", typeof (string), typeof (string), typeof (string)),
-            GetRegexMethod("Replace", "regexp_replace", typeof (string), typeof (string), typeof (string), 
+            GetRegexMethod("Replace", "regexp_replace", typeof (string), typeof (string), typeof (string),
                 typeof(RegexOptions)),
             GetRegexMethod("IsMatch", "regexp_like", typeof (string), typeof (string)),
             GetRegexMethod("IsMatch", "regexp_like", typeof (string), typeof (string), typeof(RegexOptions)),
@@ -205,7 +205,7 @@ namespace Apache.Ignite.Linq.Impl
         /// <summary>
         /// Visits the instance function.
         /// </summary>
-        private static void VisitFunc(MethodCallExpression expression, CacheQueryExpressionVisitor visitor, 
+        private static void VisitFunc(MethodCallExpression expression, CacheQueryExpressionVisitor visitor,
             string func, string suffix, params int[] adjust)
         {
             visitor.ResultBuilder.Append(func).Append("(");
@@ -358,7 +358,7 @@ namespace Apache.Ignite.Linq.Impl
         private static KeyValuePair<MethodInfo, VisitMethodDelegate> GetParameterizedTrimMethod(string name,
             string sqlName)
         {
-            return GetMethod(typeof(string), name, new[] {typeof(char[])}, 
+            return GetMethod(typeof(string), name, new[] {typeof(char[])},
                 (e, v) => VisitParameterizedTrimFunc(e, v, sqlName));
         }
 
@@ -379,4 +379,4 @@ namespace Apache.Ignite.Linq.Impl
             return GetMathMethod(name, name, argTypes);
         }
     }
-}
\ No newline at end of file
+}