test_class.file: oak-store-spi/src/test/java/org/apache/jackrabbit/oak/spi/commit/MoveTrackerTest.java
test_class.identifier: MoveTrackerTest
test_case.body: @Test
      public void testMultiMove2() {
          MoveTest test = new MoveTest()
                  .addMove("/a/b/c", "/a/f/c", "/a/b/c")
                  .addMove("/a/f/c/d", "/a/b/d", "/a/b/c/d")
                  .addMove("/a/b/d/e", "/a/f/c/e", "/a/b/c/d/e")
                  .addMove("/a/f/c/e", "/a/f/e", "/a/b/c/d/e");
          test.assertResult();
      }
test_case.class_method_signature: MoveTrackerTest.testMultiMove2()
test_case.full_signature: @Test public void testMultiMove2()
test_case.identifier: testMultiMove2
test_case.invocations: addMove addMove addMove addMove assertResult
test_case.modifiers: @Test public
test_case.parameters: ()
test_case.return: void
test_case.signature: void testMultiMove2()
focal_class.declarator: entries = new ArrayList<MoveEntry>()
focal_class.modifier: private
focal_class.original_string: private List<MoveEntry> entries = new ArrayList<MoveEntry>();
focal_class.type: List<MoveEntry>
focal_class.var_name: entries
focal_class.declarator: parentSourcePaths = new HashSet<String>()
focal_class.modifier: private
focal_class.original_string: private Set<String> parentSourcePaths = new HashSet<String>();
focal_class.type: Set<String>
focal_class.var_name: parentSourcePaths
focal_class.declarator: parentDestPaths = new HashSet<String>()
focal_class.modifier: private
focal_class.original_string: private Set<String> parentDestPaths = new HashSet<String>();
focal_class.type: Set<String>
focal_class.var_name: parentDestPaths
focal_class.file: oak-store-spi/src/main/java/org/apache/jackrabbit/oak/spi/commit/MoveTracker.java
focal_class.identifier: MoveTracker
focal_class.class_method_signature: MoveTracker.MoveTracker()
focal_class.full_signature: public  MoveTracker()
focal_class.identifier: MoveTracker
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.signature:  MoveTracker()
focal_class.class_method_signature: MoveTracker.addMove(@NotNull String sourcePath, @NotNull String destPath)
focal_class.full_signature: public void addMove(@NotNull String sourcePath, @NotNull String destPath)
focal_class.identifier: addMove
focal_class.modifiers: public
focal_class.parameters: (@NotNull String sourcePath, @NotNull String destPath)
focal_class.return: void
focal_class.signature: void addMove(@NotNull String sourcePath, @NotNull String destPath)
focal_class.class_method_signature: MoveTracker.isEmpty()
focal_class.full_signature: public boolean isEmpty()
focal_class.identifier: isEmpty
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: boolean
focal_class.signature: boolean isEmpty()
focal_class.class_method_signature: MoveTracker.getSourcePath(String destPath)
focal_class.full_signature: @Nullable public String getSourcePath(String destPath)
focal_class.identifier: getSourcePath
focal_class.modifiers: @Nullable public
focal_class.parameters: (String destPath)
focal_class.return: String
focal_class.signature: String getSourcePath(String destPath)
focal_class.class_method_signature: MoveTracker.getDestPath(String sourcePath)
focal_class.full_signature: @Nullable public String getDestPath(String sourcePath)
focal_class.identifier: getDestPath
focal_class.modifiers: @Nullable public
focal_class.parameters: (String sourcePath)
focal_class.return: String
focal_class.signature: String getDestPath(String sourcePath)
focal_class.class_method_signature: MoveTracker.containsMove(@Nullable String path)
focal_class.full_signature: public boolean containsMove(@Nullable String path)
focal_class.identifier: containsMove
focal_class.modifiers: public
focal_class.parameters: (@Nullable String path)
focal_class.return: boolean
focal_class.signature: boolean containsMove(@Nullable String path)
focal_class.class_method_signature: MoveTracker.clear()
focal_class.full_signature: public void clear()
focal_class.identifier: clear
focal_class.modifiers: public
focal_class.parameters: ()
focal_class.return: void
focal_class.signature: void clear()
focal_method.body: public void addMove(@NotNull String sourcePath, @NotNull String destPath) {
          // calculate original source path
          String originalSource = sourcePath;
          for (MoveEntry me : Lists.reverse(entries)) {
              if (Text.isDescendantOrEqual(me.destPath, sourcePath)) {
                  String relPath = PathUtils.relativize(me.destPath, sourcePath);
                  if (!relPath.isEmpty()) {
                      originalSource = me.sourcePath + '/' + relPath;
                  } else {
                      originalSource = me.sourcePath;
                  }
                  break;
              }
          }
  
          entries.add(new MoveEntry(originalSource, destPath));
      }
focal_method.class_method_signature: MoveTracker.addMove(@NotNull String sourcePath, @NotNull String destPath)
focal_method.full_signature: public void addMove(@NotNull String sourcePath, @NotNull String destPath)
focal_method.identifier: addMove
focal_method.invocations: reverse isDescendantOrEqual relativize isEmpty add
focal_method.modifiers: public
focal_method.parameters: (@NotNull String sourcePath, @NotNull String destPath)
focal_method.return: void
focal_method.signature: void addMove(@NotNull String sourcePath, @NotNull String destPath)