mirror of
https://github.com/Grasscutters/Grasscutter.git
synced 2026-02-06 18:17:00 +01:00
Revert final's added by 15e2f3ca34 (#2144)
* Revert final's added by 15e2f3ca34
* Apply suggestions from code review
Co-authored-by: Magix <27646710+KingRainbow44@users.noreply.github.com>
* Apply suggestions from code review
Co-authored-by: Magix <27646710+KingRainbow44@users.noreply.github.com>
---------
Co-authored-by: Magix <27646710+KingRainbow44@users.noreply.github.com>
This commit is contained in:
@@ -57,7 +57,7 @@ public class TsvUtils {
|
||||
private static final Function<String, Object> parseLong =
|
||||
value -> (long) Double.parseDouble(value); // Long::parseLong;
|
||||
private static final Map<Class<?>, Function<String, Object>> enumTypeParsers = new HashMap<>();
|
||||
private static final Map<Type, Function<String, Object>> primitiveTypeParsers =
|
||||
private final static Map<Type, Function<String, Object>> primitiveTypeParsers =
|
||||
Map.ofEntries(
|
||||
Map.entry(String.class, parseString),
|
||||
Map.entry(Integer.class, parseInt),
|
||||
@@ -72,7 +72,7 @@ public class TsvUtils {
|
||||
Map.entry(boolean.class, Boolean::parseBoolean));
|
||||
private static final Map<Type, Function<String, Object>> typeParsers =
|
||||
new HashMap<>(primitiveTypeParsers);
|
||||
private static final Map<Class<?>, Map<String, FieldParser>> cachedClassFieldMaps =
|
||||
private final static Map<Class<?>, Map<String, FieldParser>> cachedClassFieldMaps =
|
||||
new HashMap<>();
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
|
||||
Reference in New Issue
Block a user