add initRecompile for Bazel

GitOrigin-RevId: b9a9e9e700fd9fd62b5fb92f5a127ed90bb6798b
This commit is contained in:
Vladimir Krivosheev
2025-01-18 17:22:42 +00:00
committed by intellij-monorepo-bot
parent d73de82b28
commit 29ddb5d3bc
@@ -176,6 +176,20 @@ public final class FilesDelta {
}
}
// used by Bazel
@SuppressWarnings("unused")
public void initRecompile(@NotNull Map<BuildRootDescriptor, Set<Path>> filesToRecompile) {
lockData();
try {
assert this.filesToRecompile.isEmpty();
assert this.deletedPaths.isEmpty();
this.filesToRecompile.putAll(filesToRecompile);
}
finally {
unlockData();
}
}
public boolean markRecompileIfNotDeleted(@NotNull BuildRootDescriptor root, @NotNull Path file) {
lockData();
try {
@@ -311,18 +325,4 @@ public final class FilesDelta {
unlockData();
}
}
// used by Bazel
@SuppressWarnings("unused")
public void clearRecompile(@NotNull List<BuildRootDescriptor> roots) {
lockData();
try {
for (BuildRootDescriptor root : roots) {
filesToRecompile.remove(root);
}
}
finally {
unlockData();
}
}
}