MCPcopy Create free account
hub / github.com/Teneted/Tenet / ModList

Method ModList

src/main/java/net/minecraftforge/fml/ModList.java:68–78  ·  view source on GitHub ↗
(final List<ModFile> modFiles, final List<ModInfo> sortedList)

Source from the content-addressed store, hash-verified

66 private List<ModFileScanData> modFileScanData;
67
68 private ModList(final List<ModFile> modFiles, final List<ModInfo> sortedList)
69 {
70 this.modFiles = modFiles.stream().map(ModFile::getModFileInfo).map(ModFileInfo.class::cast).collect(Collectors.toList());
71 this.sortedList = sortedList.stream().
72 map(ModInfo.class::cast).
73 collect(Collectors.toList());
74 this.fileById = this.modFiles.stream().map(ModFileInfo::getMods).flatMap(Collection::stream).
75 map(ModInfo.class::cast).
76 collect(Collectors.toMap(ModInfo::getModId, ModInfo::getOwningFile));
77 CrashReportExtender.registerCrashCallable("Mod List", this::crashReport);
78 }
79
80 private String getModContainerState(String modId) {
81 return getModContainerById(modId).map(ModContainer::getCurrentState).map(Object::toString).orElse("NONE");

Callers

nothing calls this directly

Calls 4

registerCrashCallableMethod · 0.95
streamMethod · 0.80
mapMethod · 0.45
flatMapMethod · 0.45

Tested by

no test coverage detected