summaryrefslogtreecommitdiff
path: root/src/cuchaz/enigma/convert/MatchesReader.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/cuchaz/enigma/convert/MatchesReader.java')
-rw-r--r--src/cuchaz/enigma/convert/MatchesReader.java8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/cuchaz/enigma/convert/MatchesReader.java b/src/cuchaz/enigma/convert/MatchesReader.java
index 808f8d0..b43535c 100644
--- a/src/cuchaz/enigma/convert/MatchesReader.java
+++ b/src/cuchaz/enigma/convert/MatchesReader.java
@@ -14,19 +14,19 @@ import cuchaz.enigma.mapping.ClassEntry;
14 14
15public class MatchesReader { 15public class MatchesReader {
16 16
17 public static Matches read(File file) 17 public static ClassMatches readClasses(File file)
18 throws IOException { 18 throws IOException {
19 try (BufferedReader in = new BufferedReader(new FileReader(file))) { 19 try (BufferedReader in = new BufferedReader(new FileReader(file))) {
20 Matches matches = new Matches(); 20 ClassMatches matches = new ClassMatches();
21 String line = null; 21 String line = null;
22 while ((line = in.readLine()) != null) { 22 while ((line = in.readLine()) != null) {
23 matches.add(readMatch(line)); 23 matches.add(readClassMatch(line));
24 } 24 }
25 return matches; 25 return matches;
26 } 26 }
27 } 27 }
28 28
29 private static ClassMatch readMatch(String line) 29 private static ClassMatch readClassMatch(String line)
30 throws IOException { 30 throws IOException {
31 String[] sides = line.split(":", 2); 31 String[] sides = line.split(":", 2);
32 return new ClassMatch(readClasses(sides[0]), readClasses(sides[1])); 32 return new ClassMatch(readClasses(sides[0]), readClasses(sides[1]));