[ 
https://issues.apache.org/jira/browse/TINKERPOP-1552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16029239#comment-16029239
 ] 

Jorge Bay commented on TINKERPOP-1552:
--------------------------------------

I had some time to look into [~Florian Hockmann] contribution and it's looking 
really good!

Before going into further technical detail, I would like to discuss some high 
level decisions:

1) Naming convention
The proposed C# GLV uses pascal case, as opposed to lower camel case, for 
example:
{code}
var traversal = g.V().Has("name","marko").OutE("created")
{code}
Instead of lower camel case
{code}
var traversal = g.V().has("name","marko").outE("created")
{code}
This convention is used in .NET for properties and method declarations. 
Pros: it feels very natural for .NET devs
Cons: it's different from Gremlin conventions and it won't allow "copy/pasting" 
from traversal samples.
For the Python GLV, we went for Gremlin conventions instead of more pythonesque 
{{snake_case}}. I think that now is a good moment to find a general rule: 
should we always use Gremlin conventions for GLVs? (think coding languages with 
different name conventions, ie: C#,  Ruby, PHP, Go, ...)
I'm +1 on using Gremlin conventions.
A similar note goes for {{ITraversal}}, the traversal interface with {{I}} 
prefix, common in .NET world.

2) Generics
Like the Java implementation, traversal interfaces and classes should be 
generic, it should be {{Traversal<S, E>}}, {{DefaultTraversal<S, E>}} and so on.

3) Traversal should be iterable
Like the Java and Python implementations, the traversal should be iterable 
allowing {{foreach}} and other built-in enumeration mechanism.
In the C# case, it should implement {{IEnumerable<E>}} interface.

> C# Gremlin Language Variant
> ---------------------------
>
>                 Key: TINKERPOP-1552
>                 URL: https://issues.apache.org/jira/browse/TINKERPOP-1552
>             Project: TinkerPop
>          Issue Type: Improvement
>          Components: language-variant
>    Affects Versions: 3.2.3
>            Reporter: Jorge Bay
>
> It would be nice to have a C# GLV that runs under .NET Framework 4.5+ and 
> .NET Core.
> The maven build could use the Exec Maven Plugin to exec .NET Core's [dotnet 
> test|https://www.microsoft.com/net/core#macos] command.
> Some requirements, from the mailing list (edited):
> {quote}
> 1. The GLV should keep in line with class/method names of the java API
> where possible to ensure consistency of feel across languages.
> 2. There needs to be adequate tests (we're still discussing the approach to
> testing GLVs and i think that needs to be tackled sooner than later as more
> GLVs start to come in). Those tests should produce xunit style output
> unless there is some good reason not to.
> 3. There needs to be adequate documentation (e.g. Reference docs)
> 4. The build/deploy process needs to be bound to maven which might be one of 
> the trickier bits to deal with.
> {quote}



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to