mirror of
https://github.com/Maschell/JNUSLib.git
synced 2024-11-05 07:45:11 +01:00
Added options to disable parellelisation
This commit is contained in:
parent
8ef84f48dd
commit
a46011c6ea
@ -95,7 +95,7 @@ public final class ExtractionService {
|
||||
|
||||
public void extractEncryptedContentFilesTo(List<Content> list, String outputFolder, boolean withHashes) throws IOException {
|
||||
Utils.createDir(outputFolder);
|
||||
if (parallelizable) {
|
||||
if (parallelizable && Settings.ALLOW_PARALLELISATION) {
|
||||
try {
|
||||
CompletableFuture.allOf(list.stream().map((Content c) -> CompletableFuture.runAsync(() -> {
|
||||
try {
|
||||
@ -105,7 +105,7 @@ public final class ExtractionService {
|
||||
}
|
||||
})).toArray(CompletableFuture[]::new)).get();
|
||||
} catch (InterruptedException | ExecutionException e) {
|
||||
throw new IOException(e);
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
} else {
|
||||
for (Content c : list) {
|
||||
|
@ -29,6 +29,7 @@ public class Settings {
|
||||
public static final String WOOMY_METADATA_FILENAME = "metadata.xml";
|
||||
public static final String H3_EXTENTION = ".h3";
|
||||
public static final String USER_AGENT = "Mozilla/5.0 (Nintendo WiiU) AppleWebKit/536.28 (KHTML, like Gecko) NX/3.0.3.12.12 NintendoBrowser/3.0.0.9561.US";
|
||||
public static final boolean ALLOW_PARALLELISATION = true;
|
||||
|
||||
public static byte[] commonKey = new byte[0x10];
|
||||
public static int WIIU_DECRYPTED_AREA_OFFSET = 0x18000;
|
||||
|
Loading…
Reference in New Issue
Block a user