Christopher Smith created TINKERPOP-2515: --------------------------------------------
Summary: Add clone method to GraphTraversal interface Key: TINKERPOP-2515 URL: https://issues.apache.org/jira/browse/TINKERPOP-2515 Project: TinkerPop Issue Type: Improvement Affects Versions: 3.4.9 Reporter: Christopher Smith The canonical recommendation for reusing traversal parts (e.g., I have a method that takes a {{GraphTraversal}} as a parameter, and I need to apply {{.id()}} to it) is to call {{clone()}} on the traversal. However, the interface {{GraphTraversal}} does not actually provide a {{clone()}} method, and {{Object#clone()}} is protected. The universal actual implementations {{DefaultTraversal}} and {{DefaultGraphTraversal}} explicitly expose {{clone()}}, but they're hidden behind the interfaces. To provide Java/STC compatibility, {{GraphTraversal}} (and possibly {{Traversal}}) should expose the {{clone()}} methods. -- This message was sent by Atlassian Jira (v8.3.4#803005)