Formatting and organizing imports

This commit is contained in:
Maschell 2019-04-10 18:57:55 +02:00
parent b6a5946f9e
commit 44b04ea637
9 changed files with 2 additions and 12 deletions

View File

@ -27,8 +27,6 @@ import java.util.regex.Pattern;
import java.util.stream.Collectors; import java.util.stream.Collectors;
import java.util.stream.Stream; import java.util.stream.Stream;
import org.apache.commons.io.FilenameUtils;
import de.mas.wiiu.jnus.entities.TMD; import de.mas.wiiu.jnus.entities.TMD;
import de.mas.wiiu.jnus.entities.Ticket; import de.mas.wiiu.jnus.entities.Ticket;
import de.mas.wiiu.jnus.entities.content.Content; import de.mas.wiiu.jnus.entities.content.Content;
@ -39,7 +37,6 @@ import de.mas.wiiu.jnus.interfaces.NUSDataProvider;
import de.mas.wiiu.jnus.utils.FSTUtils; import de.mas.wiiu.jnus.utils.FSTUtils;
import lombok.Getter; import lombok.Getter;
import lombok.Setter; import lombok.Setter;
import lombok.val;
public class NUSTitle { public class NUSTitle {
@Getter @Setter private FST FST; @Getter @Setter private FST FST;

View File

@ -19,7 +19,6 @@ package de.mas.wiiu.jnus;
import java.io.IOException; import java.io.IOException;
import java.io.InputStream; import java.io.InputStream;
import java.text.ParseException; import java.text.ParseException;
import java.util.Arrays;
import java.util.Map; import java.util.Map;
import java.util.Optional; import java.util.Optional;
import java.util.function.Supplier; import java.util.function.Supplier;
@ -30,7 +29,6 @@ import de.mas.wiiu.jnus.entities.content.Content;
import de.mas.wiiu.jnus.entities.fst.FST; import de.mas.wiiu.jnus.entities.fst.FST;
import de.mas.wiiu.jnus.interfaces.NUSDataProvider; import de.mas.wiiu.jnus.interfaces.NUSDataProvider;
import de.mas.wiiu.jnus.utils.StreamUtils; import de.mas.wiiu.jnus.utils.StreamUtils;
import de.mas.wiiu.jnus.utils.Utils;
import de.mas.wiiu.jnus.utils.cryptography.AESDecryption; import de.mas.wiiu.jnus.utils.cryptography.AESDecryption;
public class NUSTitleLoader { public class NUSTitleLoader {

View File

@ -24,7 +24,6 @@ import java.io.InputStream;
import java.nio.file.Files; import java.nio.file.Files;
import java.util.Optional; import java.util.Optional;
import de.mas.wiiu.jnus.NUSTitle;
import de.mas.wiiu.jnus.Settings; import de.mas.wiiu.jnus.Settings;
import de.mas.wiiu.jnus.entities.content.Content; import de.mas.wiiu.jnus.entities.content.Content;
import de.mas.wiiu.jnus.interfaces.NUSDataProvider; import de.mas.wiiu.jnus.interfaces.NUSDataProvider;

View File

@ -23,7 +23,6 @@ import java.util.Optional;
import java.util.zip.ZipEntry; import java.util.zip.ZipEntry;
import java.util.zip.ZipException; import java.util.zip.ZipException;
import de.mas.wiiu.jnus.NUSTitle;
import de.mas.wiiu.jnus.Settings; import de.mas.wiiu.jnus.Settings;
import de.mas.wiiu.jnus.entities.content.Content; import de.mas.wiiu.jnus.entities.content.Content;
import de.mas.wiiu.jnus.implementations.woomy.WoomyInfo; import de.mas.wiiu.jnus.implementations.woomy.WoomyInfo;

View File

@ -15,7 +15,6 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>. * along with this program. If not, see <http://www.gnu.org/licenses/>.
****************************************************************************/ ****************************************************************************/
package de.mas.wiiu.jnus.interfaces; package de.mas.wiiu.jnus.interfaces;
import java.io.IOException; import java.io.IOException;

View File

@ -31,6 +31,5 @@ public class CheckSumWrongException extends Exception {
super(string); super(string);
this.givenHash = given; this.givenHash = given;
this.expectedHash = expected; this.expectedHash = expected;
} }
} }

View File

@ -42,7 +42,6 @@ public abstract class Downloader {
ByteArrayOutputStream byteArray = new ByteArrayOutputStream(); ByteArrayOutputStream byteArray = new ByteArrayOutputStream();
if (responseCode == HttpURLConnection.HTTP_OK) { if (responseCode == HttpURLConnection.HTTP_OK) {
InputStream inputStream = httpConn.getInputStream(); InputStream inputStream = httpConn.getInputStream();
int bytesRead = -1; int bytesRead = -1;

View File

@ -88,7 +88,7 @@ public final class NUSDownloadService extends Downloader {
HttpURLConnection connection = (HttpURLConnection) url_obj.openConnection(); HttpURLConnection connection = (HttpURLConnection) url_obj.openConnection();
connection.setRequestProperty("User-Agent", Settings.USER_AGENT); connection.setRequestProperty("User-Agent", Settings.USER_AGENT);
String sizeString = ""; String sizeString = "";
if(size.isPresent()) { if (size.isPresent()) {
sizeString = Long.toString(size.get()); sizeString = Long.toString(size.get());
} }
connection.setRequestProperty("Range", "bytes=" + offset + "-" + sizeString); connection.setRequestProperty("Range", "bytes=" + offset + "-" + sizeString);