diff options
author | TheKodeToad <TheKodeToad@proton.me> | 2022-11-03 16:40:23 +0000 |
---|---|---|
committer | TheKodeToad <TheKodeToad@proton.me> | 2022-11-08 16:35:43 +0000 |
commit | 8ce78dcc54a8ed3e6292a8650692fa9c520a993d (patch) | |
tree | b1b188f289728d019dc259243b5c296cb1eba982 /libraries/launcher/org/prismlauncher/exception | |
parent | afe088dba18b83ae1ea79e3b31ef5026f68b7b6d (diff) | |
download | PrismLauncher-8ce78dcc54a8ed3e6292a8650692fa9c520a993d.tar.gz PrismLauncher-8ce78dcc54a8ed3e6292a8650692fa9c520a993d.tar.bz2 PrismLauncher-8ce78dcc54a8ed3e6292a8650692fa9c520a993d.zip |
Try to improve consistency
- Makes code formatting more consistent with the C++ codebase. Probably removes some trailing whitespace. Maybe it would be best to commit an Eclipse or IntelliJ code format preferences file?
- Removes obscure suppressions. I personally think it's better to only suppress warnings that javac complains about. Suppressing a lot of non-standardised warnings (many of them turned off by default even in IntelliJ) just creates needless clutter.
- Fixes some trivial warnings instead of suppressing them. serialVersionUID is sort of stupid, but I'd rather mentally ignore it or just fix it if it's really that annoying.
Signed-off-by: TheKodeToad <TheKodeToad@proton.me>
Diffstat (limited to 'libraries/launcher/org/prismlauncher/exception')
-rw-r--r-- | libraries/launcher/org/prismlauncher/exception/ParameterNotFoundException.java | 7 | ||||
-rw-r--r-- | libraries/launcher/org/prismlauncher/exception/ParseException.java | 7 |
2 files changed, 9 insertions, 5 deletions
diff --git a/libraries/launcher/org/prismlauncher/exception/ParameterNotFoundException.java b/libraries/launcher/org/prismlauncher/exception/ParameterNotFoundException.java index 48bf9f4c..ad973ace 100644 --- a/libraries/launcher/org/prismlauncher/exception/ParameterNotFoundException.java +++ b/libraries/launcher/org/prismlauncher/exception/ParameterNotFoundException.java @@ -5,6 +5,8 @@ * Copyright (C) 2022 icelimetea <fr3shtea@outlook.com> * Copyright (C) 2022 Sefa Eyeoglu <contact@scrumplex.net> * Copyright (C) 2022 Samisafool <thenerdiestguy@gmail.com> + * Copyright (C) 2022 solonovamax <solonovamax@12oclockpoint.com> + * Copyright (C) 2022 TheKodeToad <TheKodeToad@proton.me> * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -38,10 +40,10 @@ package org.prismlauncher.exception; - -@SuppressWarnings("serial") public final class ParameterNotFoundException extends IllegalArgumentException { + private static final long serialVersionUID = 1L; + public ParameterNotFoundException(String message, Throwable cause) { super(message, cause); } @@ -55,7 +57,6 @@ public final class ParameterNotFoundException extends IllegalArgumentException { } public ParameterNotFoundException() { - super(); } public static ParameterNotFoundException forParameterName(String parameterName) { diff --git a/libraries/launcher/org/prismlauncher/exception/ParseException.java b/libraries/launcher/org/prismlauncher/exception/ParseException.java index 0d5f3c10..2fd693e7 100644 --- a/libraries/launcher/org/prismlauncher/exception/ParseException.java +++ b/libraries/launcher/org/prismlauncher/exception/ParseException.java @@ -5,6 +5,8 @@ * Copyright (C) 2022 icelimetea <fr3shtea@outlook.com> * Copyright (C) 2022 Sefa Eyeoglu <contact@scrumplex.net> * Copyright (C) 2022 Samisafool <thenerdiestguy@gmail.com> + * Copyright (C) 2022 solonovamax <solonovamax@12oclockpoint.com> + * Copyright (C) 2022 TheKodeToad <TheKodeToad@proton.me> * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -38,10 +40,10 @@ package org.prismlauncher.exception; - -@SuppressWarnings({ "serial", "unused" }) public final class ParseException extends IllegalArgumentException { + private static final long serialVersionUID = 1L; + public ParseException(String message) { super(message); } @@ -65,4 +67,5 @@ public final class ParseException extends IllegalArgumentException { public static ParseException forInputString(String inputString, Throwable cause) { return new ParseException(String.format("Could not parse input string '%s'", inputString), cause); } + } |