Closed BigBadE closed 2 years ago
The source file JarMapping.java has the following snippet: Remapper reverseMapper = new Remapper() { @Override public String map(String cls) { return clsMap.getOrDefault(cls, cls); } }; Referencing the Javadocs (https://docs.oracle.com/javase/8/docs/api/java/util/Map.html#getOrDefault-java.lang.Object-V-), you can see that this method is marked 1.8+. This is also reflected in the JavaSE 7 Javadocs where the method isn't found (https://docs.oracle.com/javase/7/docs/api/java/util/Map.html).
Remapper reverseMapper = new Remapper() { @Override public String map(String cls) { return clsMap.getOrDefault(cls, cls); } };
Since Spigot requires Java 8 anyways, there is no reason to stay behind on Java 7.
I also added support for loading mappings via InputStream and File. This allows mappings to be loaded from a URL/URI.
The source file JarMapping.java has the following snippet:
Remapper reverseMapper = new Remapper() { @Override public String map(String cls) { return clsMap.getOrDefault(cls, cls); } };
Referencing the Javadocs (https://docs.oracle.com/javase/8/docs/api/java/util/Map.html#getOrDefault-java.lang.Object-V-), you can see that this method is marked 1.8+. This is also reflected in the JavaSE 7 Javadocs where the method isn't found (https://docs.oracle.com/javase/7/docs/api/java/util/Map.html).Since Spigot requires Java 8 anyways, there is no reason to stay behind on Java 7.
I also added support for loading mappings via InputStream and File. This allows mappings to be loaded from a URL/URI.