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

Reduce Traversal.isRoot() to a check of EmptyStep

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Done
    • 3.5.0
    • 3.5.0
    • process

    Description

      The Traversal.isRoot() default implementation looks like:

              public default boolean isRoot() {
                  return null == getParent() || getParent() instanceof EmptyStep;
              }
      

      Could this be reduced to just a check of EmptyStep - i.e. can the parent never be null

      Attachments

        Issue Links

          Activity

            People

              spmallette Stephen Mallette
              spmallette Stephen Mallette
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: