tinkerpop-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From florianhockm...@apache.org
Subject [4/6] tinkerpop git commit: TINKERPOP-1868 Remove unnecessary spaces
Date Sun, 21 Jan 2018 12:56:27 GMT
TINKERPOP-1868 Remove unnecessary spaces


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

Branch: refs/heads/master
Commit: 535b309e61f1dc5291c25f3ff36e42d008c264ab
Parents: 944c2c8
Author: florianhockmann <fh@florian-hockmann.de>
Authored: Thu Jan 18 19:37:07 2018 +0100
Committer: florianhockmann <fh@florian-hockmann.de>
Committed: Thu Jan 18 19:37:07 2018 +0100

----------------------------------------------------------------------
 gremlin-dotnet/glv/GraphTraversal.template      |   6 +-
 .../glv/GraphTraversalSource.template           |   6 +-
 gremlin-dotnet/glv/generate.groovy              |   3 +-
 .../Process/Traversal/GraphTraversal.cs         | 758 +++++++++----------
 .../Process/Traversal/GraphTraversalSource.cs   |  32 +-
 5 files changed, 403 insertions(+), 402 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/535b309e/gremlin-dotnet/glv/GraphTraversal.template
----------------------------------------------------------------------
diff --git a/gremlin-dotnet/glv/GraphTraversal.template b/gremlin-dotnet/glv/GraphTraversal.template
index 810516f..6738467 100644
--- a/gremlin-dotnet/glv/GraphTraversal.template
+++ b/gremlin-dotnet/glv/GraphTraversal.template
@@ -65,10 +65,10 @@ namespace Gremlin.Net.Process.Traversal
         /// <summary>
         ///     Adds the <%= method.methodName %> step to this <see cref="GraphTraversal{SType,
EType}" />.
         /// </summary>
-        public GraphTraversal< <%= method.t1 %> , <%= method.t2 %> > <%=
toCSharpMethodName.call(method.methodName) %><%= method.tParam %> (<%= method.parameters
%>)
+        public GraphTraversal<$method.t1, $method.t2> <%= toCSharpMethodName.call(method.methodName)
%><%= method.tParam %> (<%= method.parameters %>)
         {
         <%  if (method.parameters.contains("params ")) {
-      %>    var args = new List< <%= method.argsListType %> >(<%= method.paramNames.init().size()
%> + <%= method.paramNames.last() %>.Length) {<%= method.paramNames.init().join(",
") %>};
+      %>    var args = new List<$method.argsListType>(<%= method.paramNames.init().size()
%> + <%= method.paramNames.last() %>.Length) {<%= method.paramNames.init().join(",
") %>};
             args.AddRange(<%= method.paramNames.last() %>);
             Bytecode.AddStep("<%= method.methodName %>", args.ToArray());<%
             }
@@ -76,7 +76,7 @@ namespace Gremlin.Net.Process.Traversal
       %>    Bytecode.AddStep("<%= method.methodName %>"<% if (method.parameters)
out << ', '+ method.paramNames.join(", ") %>);<%
             }
         %>
-            return Wrap< <%= method.t1 %> , <%= method.t2 %> >(this);
+            return Wrap<$method.t1, $method.t2>(this);
         }
 <% } %>
     }

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/535b309e/gremlin-dotnet/glv/GraphTraversalSource.template
----------------------------------------------------------------------
diff --git a/gremlin-dotnet/glv/GraphTraversalSource.template b/gremlin-dotnet/glv/GraphTraversalSource.template
index f8b0acf..afa4297 100644
--- a/gremlin-dotnet/glv/GraphTraversalSource.template
+++ b/gremlin-dotnet/glv/GraphTraversalSource.template
@@ -127,11 +127,11 @@ namespace Gremlin.Net.Process.Traversal
         ///     Spawns a <see cref="GraphTraversal{SType, EType}" /> off this graph
traversal source and adds the <%= method.methodName %> step to that
         ///     traversal.
         /// </summary>
-        public GraphTraversal< <%= method.typeNames.join(",") %> > <%= toCSharpMethodName.call(method.methodName)
%><%= method.tParam %>(<%= method.parameters %>)
+        public GraphTraversal<$method.typeNameString> <%= toCSharpMethodName.call(method.methodName)
%><%= method.tParam %>(<%= method.parameters %>)
         {
-            var traversal = new GraphTraversal< <%= method.typeNames.join(",") %>
>(TraversalStrategies, new Bytecode(Bytecode));
+            var traversal = new GraphTraversal<$method.typeNameString>(TraversalStrategies,
new Bytecode(Bytecode));
             <%  if (method.parameters.contains("params ")) {
-          %>var args = new List< <%= method.argsListType %> >(<%= method.paramNames.init().size()
%> + <%= method.paramNames.last() %>.Length) {<%= method.paramNames.init().join(",
") %>};
+          %>var args = new List<$method.argsListType>(<%= method.paramNames.init().size()
%> + <%= method.paramNames.last() %>.Length) {<%= method.paramNames.init().join(",
") %>};
             args.AddRange(<%= method.paramNames.last() %>);
             traversal.Bytecode.AddStep("<%= method.methodName %>", args.ToArray());<%
             }

http://git-wip-us.apache.org/repos/asf/tinkerpop/blob/535b309e/gremlin-dotnet/glv/generate.groovy
----------------------------------------------------------------------
diff --git a/gremlin-dotnet/glv/generate.groovy b/gremlin-dotnet/glv/generate.groovy
index 81b2f83..12cfa88 100644
--- a/gremlin-dotnet/glv/generate.groovy
+++ b/gremlin-dotnet/glv/generate.groovy
@@ -265,12 +265,13 @@ def binding = ["pmethods": P.class.getMethods().
                         unique { a,b -> a.name <=> b.name ?: getCSharpParamTypeString(a)
<=> getCSharpParamTypeString(b) }.
                         collect { javaMethod ->
                             def typeNames = getJavaGenericTypeParameterTypeNames(javaMethod)
+                            def typeNameString = typeNames.join(", ")
                             def t2 = toCSharpType(typeNames[1])
                             def tParam = getCSharpGenericTypeParam(t2)
                             def parameters = getCSharpParamString(javaMethod, true)
                             def paramNames = getParamNames(javaMethod.parameters)
                             def argsListType = getArgsListType(parameters)
-                            return ["methodName": javaMethod.name, "typeNames": typeNames,
"tParam":tParam, "parameters":parameters, "paramNames":paramNames, "argsListType":argsListType]
+                            return ["methodName": javaMethod.name, "typeNameString": typeNameString,
"tParam":tParam, "parameters":parameters, "paramNames":paramNames, "argsListType":argsListType]
                         },
                "graphStepMethods": GraphTraversal.getMethods().
                         findAll { GraphTraversal.class.equals(it.returnType) }.


Mime
View raw message