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>
This commit is contained in:
@ -49,8 +49,8 @@ import java.lang.reflect.Modifier;
|
||||
import java.util.logging.Level;
|
||||
import java.util.logging.Logger;
|
||||
|
||||
|
||||
public final class ReflectionUtils {
|
||||
|
||||
private static final Logger LOGGER = Logger.getLogger("ReflectionUtils");
|
||||
|
||||
private ReflectionUtils() {
|
||||
@ -160,10 +160,9 @@ public final class ReflectionUtils {
|
||||
* @throws NoSuchMethodException If no method matching the correct signature can be found
|
||||
* @throws IllegalAccessException If method handles cannot access the entrypoint
|
||||
*/
|
||||
public static MethodHandle findMainEntrypoint(String entrypointClassName) throws
|
||||
ClassNotFoundException,
|
||||
NoSuchMethodException,
|
||||
IllegalAccessException {
|
||||
public static MethodHandle findMainMethod(String entrypointClassName)
|
||||
throws ClassNotFoundException, NoSuchMethodException, IllegalAccessException {
|
||||
return findMainEntrypoint(ClassLoader.getSystemClassLoader().loadClass(entrypointClassName));
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -36,8 +36,8 @@
|
||||
|
||||
package org.prismlauncher.utils;
|
||||
|
||||
|
||||
public final class StringUtils {
|
||||
|
||||
private StringUtils() {
|
||||
}
|
||||
|
||||
@ -46,6 +46,7 @@ public final class StringUtils {
|
||||
if (splitPoint == -1)
|
||||
return null;
|
||||
|
||||
return new String[]{ input.substring(0, splitPoint), input.substring(splitPoint + 1) };
|
||||
return new String[] { input.substring(0, splitPoint), input.substring(splitPoint + 1) };
|
||||
}
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user