mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-01-08 15:09:39 +07:00
[updater] dead code elimination
GitOrigin-RevId: 6712258b10e8993acda416d7f2c8d575acb5d779
This commit is contained in:
committed by
intellij-monorepo-bot
parent
c176f726bf
commit
63cb6eec67
@@ -5,15 +5,13 @@ import java.io.File;
|
||||
import java.util.*;
|
||||
|
||||
public final class DiffCalculator {
|
||||
public static Result calculate(Map<String, Long> oldChecksums, Map<String, Long> newChecksums) {
|
||||
return calculate(oldChecksums, newChecksums, Set.of(), Set.of(), false);
|
||||
}
|
||||
|
||||
public static Result calculate(Map<String, Long> oldChecksums,
|
||||
Map<String, Long> newChecksums,
|
||||
Set<String> critical,
|
||||
Set<String> optional,
|
||||
boolean lookForMoved) {
|
||||
public static Result calculate(
|
||||
Map<String, Long> oldChecksums,
|
||||
Map<String, Long> newChecksums,
|
||||
Set<String> critical,
|
||||
Set<String> optional,
|
||||
boolean lookForMoved
|
||||
) {
|
||||
Result result = new Result();
|
||||
result.commonFiles = collect(oldChecksums, newChecksums, critical, true);
|
||||
result.filesToDelete = withAllRemoved(oldChecksums, newChecksums);
|
||||
|
||||
@@ -24,16 +24,6 @@ public class ZipOutputWrapper implements AutoCloseable {
|
||||
myCompressed = compressionLevel > 0;
|
||||
}
|
||||
|
||||
public OutputStream zipStream(String entryPath) {
|
||||
return new OptByteArrayOutputStream() {
|
||||
@Override
|
||||
public void close() throws IOException {
|
||||
super.close();
|
||||
zipBytes(entryPath, this);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
public void zipEntry(ZipEntry entry, InputStream from) throws IOException {
|
||||
if (entry.isDirectory()) {
|
||||
addDirs(entry.getName(), true);
|
||||
@@ -104,4 +94,4 @@ public class ZipOutputWrapper implements AutoCloseable {
|
||||
cs.update(buf, 0, count);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user