Uploaded image for project: 'TinkerPop'
  1. TinkerPop
  2. TINKERPOP-882

Develop a less error prone way for rewriting strategies

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Incomplete
    • 3.0.2-incubating
    • None
    • process
    • None

    Description

      When someone writes a TraversalStrategy it is of the nature:

      if(step instanceof SelectStep && ((SelectStep)step).getLocalChildren().size() > 1) {
        TraversalHelper.insertStep(new IdentityStep(), step, traversal);
      }
      

      It can start to get hairy looking fast. It would be great if we could study the strategies we have thus far and see if there are patterns we can extract encapsulate such behaviors in new methods in TraversalHelper. I don't have any good ideas on how to do this, but I think we need it. My only thought was a "regular expression" language for our traversals so we can pattern match ON the traversal.

      Attachments

        Activity

          People

            Unassigned Unassigned
            okram Marko A. Rodriguez
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: