Add the method"downloadContentToByteArray" to the NUSDownloadService

This commit is contained in:
Maschell 2020-12-20 11:24:23 +01:00
parent 897afeeb2a
commit 135e78feda

View File

@ -65,6 +65,11 @@ public final class NUSDownloadService extends Downloader {
return downloadFileToByteArray(URL); return downloadFileToByteArray(URL);
} }
public byte[] downloadContentToByteArray(long titleID, int contentId) throws IOException {
String URL = URL_BASE + "/" + String.format("%016X/%08X", titleID, contentId);
return downloadFileToByteArray(URL);
}
/** /**
* For the cert we need a part from a ticket. For this we simply load a public ticket and use it. * For the cert we need a part from a ticket. For this we simply load a public ticket and use it.
*/ */