Skip to content

Commit

Permalink
use Collection library
Browse files Browse the repository at this point in the history
  • Loading branch information
LoiNguyenCS committed Dec 1, 2023
1 parent 86aa443 commit 782646f
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
import java.nio.charset.StandardCharsets;
import java.nio.file.Files;
import java.nio.file.Path;
import java.util.Collection;
import java.util.HashMap;
import java.util.HashSet;
import java.util.List;
Expand Down Expand Up @@ -130,8 +131,7 @@ public static void performMinimization(
cu.accept(finder, null);
}
Set<String> setOfUsedAndUnsolvedFile = finder.getListOfUsedYetUnsolvedFile();
parsedTargetFiles.putAll(
getUpdateParsedTargetFiles(setOfUsedAndUnsolvedFile.stream().toList(), root));
parsedTargetFiles.putAll(getUpdateParsedTargetFiles(setOfUsedAndUnsolvedFile, root));
createdClass.addAll(
updateSyntheticFiles(addMissingClass, parsedTargetFiles, targetFiles, root));
parsedTargetFiles = getUpdateParsedTargetFiles(targetFiles, root);
Expand Down Expand Up @@ -237,7 +237,7 @@ public static void performMinimization(
* @return parsedTargetFiles an updated version of parsedTargetFiles
*/
public static Map<String, CompilationUnit> getUpdateParsedTargetFiles(
List<String> targetFiles, String root) throws IOException {
Collection<String> targetFiles, String root) throws IOException {
Map<String, CompilationUnit> parsedTargetFiles = new HashMap<>();
for (String targetFile : targetFiles) {
parsedTargetFiles.put(targetFile, parseJavaFile(root, targetFile));
Expand Down

0 comments on commit 782646f

Please sign in to comment.