[ https://issues.apache.org/jira/browse/TINKERPOP-2824?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17690538#comment-17690538 ]
ASF GitHub Bot commented on TINKERPOP-2824: ------------------------------------------- vkagamlyk commented on code in PR #1843: URL: https://github.com/apache/tinkerpop/pull/1843#discussion_r1110222260 ########## gremlin-dotnet/src/Gremlin.Net/Structure/Edge.cs: ########## @@ -52,6 +55,15 @@ public Edge(object? id, Vertex outV, string label, Vertex inV) /// </summary> public Vertex OutV { get; } + /// <summary> + /// Get property by key + /// </summary> + /// <returns>property or null when not found</returns> + public Property? Property(string key) Review Comment: I considered 3 options: 1. minimal change, just extend `Vertex` and `Edge` classes with new typed `Property` method like `public Property? Property(string key)` 2. non-breaking change, add dynamic `Property` method to the base `Element` class like `public dynamic? Property(string key)`, it's less convenient for users 3. breaking change, make `Element' type generic `Element<PropertyType>` and method like `public T? Property(string key)` first one is safest and at the same time user-friendly, so I chose it > Properties on Elements > ---------------------- > > Key: TINKERPOP-2824 > URL: https://issues.apache.org/jira/browse/TINKERPOP-2824 > Project: TinkerPop > Issue Type: Improvement > Components: dotnet, driver, go, javascript, process, python > Affects Versions: 3.5.4 > Reporter: Valentyn Kahamlyk > Assignee: Valentyn Kahamlyk > Priority: Major > > Problem: When a user writes `g.V()` they get back a Vertex object. The > problem is that depending on the execution context of the traversal, the > result could be quite different, with or without properties. > Solution: Implement new finalization strategy DetachStrategy(detachMode, > properties) where mode is one of ALL, NONE or CUSTOM. `properties` is list of > properties name, are taken into account only for CUSTOM mode. > Discussion thread in dev list: [Proposal to handle properties on response > Elements-Apache Mail > Archives|https://lists.apache.org/thread/l8rw7ydj7kym8vhtwk50nhbp45ng9986] > Stephen's thread in dev list: [The Issue of Detachment-Apache Mail > Archives|https://lists.apache.org/thread/xltcon4zxnwq4fyw2r2126syyrqm8spy] -- This message was sent by Atlassian Jira (v8.20.10#820010)