Refactor Line separator for Mac and add APIFootballProvider

This commit is contained in:
Julian Arndt
2020-09-29 17:43:05 +02:00
parent a484010285
commit 9c88c28151
10 changed files with 161 additions and 138 deletions

View File

@@ -7,6 +7,7 @@ import org.json.simple.JSONObject;
import org.json.simple.parser.JSONParser;
import org.json.simple.parser.ParseException;
import java.io.File;
import java.io.IOException;
import java.net.URL;
import java.nio.charset.StandardCharsets;
@@ -55,7 +56,7 @@ public class APIFootballMatch extends BaseMatch {
JSONObject object = null;
//JSON parser object to parse read file
JSONParser jsonParser = new JSONParser();
URL url = Resources.getResource((this.season + 1) + "\\API-Football\\" + filename);
URL url = Resources.getResource((this.season + 1) + File.separator + "API-Football" + File.separator + filename);
String jsonConfig = null;
try {