Cole-Greer commented on code in PR #3133:
URL: https://github.com/apache/tinkerpop/pull/3133#discussion_r2155752316
##########
gremlin-dotnet/src/Gremlin.Net/Process/Traversal/GraphTraversal.cs:
##########
@@ -862,6 +862,22 @@ public GraphTraversal<TStart, string> Format(string format)
return Wrap<TStart, string>(this);
}
+ /// <summary>
+ /// Adds the from step to this <see cref="GraphTraversal{SType,
EType}" />.
+ /// </summary>
+ public GraphTraversal<TStart, TEnd> From (object? fromStepLabel)
+ {
+ if (fromStepLabel is string fromStepLabelString)
+ {
+ return From(fromStepLabelString);
+ }
+ if (fromStepLabel is int fromStepLabelSInteger)
+ {
+ return From(new Vertex(fromStepLabelSInteger));
+ }
+ throw new ArgumentException($"{fromStepLabel} is not a valid step
label");
+ }
Review Comment:
After further consideration I think this vertex -> id sugar is best left
exclusively to the master branch
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]