+ static final String INPUTS = "data/inputs/";
+ static final String STOPLISTS = "data/inputs/stoplists/";
+ static final String OUTPUTS = "data/outputs/";
+
+ public static <E> void main(final String[] args) throws Exception {
+
+ // Builds all the dictionaries it can, outputs list to a text file.
+
+ final Map<String,String> isoToWikiName = new LinkedHashMap<String, String>(WiktionaryLangs.isoCodeToWikiName);
+ isoToWikiName.remove("EN");
+ isoToWikiName.remove("DE");
+
+ final Map<String,String> isoToDedication = new LinkedHashMap<String, String>();
+ isoToDedication.put("AF", "Afrikaans dictionary dedicated to Heiko and Mariëtte Horn.");
+ isoToDedication.put("HR", "Croatian dictionary dedicated to Ines Viskic and Miro Kresonja.");
+ isoToDedication.put("NL", "Dutch dictionary dedicated to Mike LeBeau.");
+ // German handled in file.
+ isoToDedication.put("EL", "Greek dictionary dedicated to Noah Egge.");
+ isoToDedication.put("IT", "Italian dictionary dedicated to Carolina Tropini, my favorite stardust in the whole universe! Ti amo!");
+ isoToDedication.put("KO", "Korean dictionary dedicated to Ande Elwood--fall fashion und Fernsehturms!");
+ isoToDedication.put("PT", "Portuguese dictionary dedicated to Carlos Melo, one Tough Mudder.");
+ isoToDedication.put("RO", "Romanian dictionary dedicated to Radu Teodorescu.");
+ isoToDedication.put("RU", "Russian dictionary dedicated to Maxim Aronin--best friend always!.");
+ isoToDedication.put("SR", "Serbian dictionary dedicated to Filip Crnogorac--thanks for the honey.");
+ isoToDedication.put("ES", "Spanish dictionary made especially for Carolina Tropini! <3 XoXoXXXXX!");
+ isoToDedication.put("SV", "Swedish dictionary dedicated to Kajsa Palmblad--björn kramar!");
+
+ final Map<String,String> isoToStoplist = new LinkedHashMap<String, String>();
+ isoToStoplist.put("DE", "de.txt");
+ isoToStoplist.put("EN", "en.txt");
+ isoToStoplist.put("ES", "es.txt");
+ isoToStoplist.put("IT", "it.txt");
+ isoToStoplist.put("FR", "fr.txt");
+
+ final Map<String,String> isoToRegex = new LinkedHashMap<String, String>();
+ // HACK: The missing "e" prevents a full match, causing "Cantonese" to be appended to the entries.
+ isoToRegex.put("ZH", "Chinese|Mandarin|Cantones");
+
+
+ // Build the non EN ones.
+
+ final String[][] nonEnPairs = new String[][] {
+
+ /*
+ {"AR", "DE" },
+ {"AR", "ES" },
+ {"AR", "FR" },
+ {"AR", "HE" },
+ {"AR", "IT" },
+ {"AR", "JA" },
+ {"AR", "RU" },
+ {"AR", "TR" }, // Turkish
+ {"AR", "ZH" },
+
+ {"DE", "AR" },
+ {"DE", "FR" },
+ {"DE", "CA" }, // Catalan
+ {"DE", "CS" }, // Czech
+ {"DE", "EO" }, // Esperanto
+ {"DE", "ES" },
+ {"DE", "FR" },
+ {"DE", "HE" },
+ {"DE", "HU" }, // Hungarian
+ {"DE", "IT" },
+ {"DE", "JA" },
+ {"DE", "LA" }, // Latin
+ {"DE", "PL" }, // Polish
+ {"DE", "RU" },
+ {"DE", "SV" }, // Swedish
+ {"DE", "TR" }, // Turkish
+ {"DE", "ZH" },
+
+
+ {"FR", "BG" }, // Bulgarian
+ {"FR", "CS" }, // Czech
+ {"FR", "DE" },
+ {"FR", "ES" },
+ {"FR", "IT" },
+ {"FR", "JA" },
+ {"FR", "LA" },
+ {"FR", "NL" }, // Dutch
+ {"FR", "RU" },
+ {"FR", "TR" }, // Turkish
+ {"FR", "ZH" },
+
+ {"IT", "DE" },
+ {"IT", "EL" }, // Greek
+ {"IT", "ES" },
+ {"IT", "FR" },
+ {"IT", "HU" },
+ {"IT", "JA" },
+ {"IT", "LA" }, // Latin
+ {"IT", "LV" }, // Latvian
+ {"IT", "NL" },
+ {"IT", "PL" },
+ {"IT", "RU" },
+ {"IT", "SV" },
+ {"IT", "TR" }, // Turkish
+ {"IT", "ZH" },
+
+ {"JA", "ZH" },
+ {"JA", "AR" },
+ {"JA", "KO" },
+
+ {"ZH", "AR" },
+ {"ZH", "DE" },
+ {"ZH", "ES" },
+ {"ZH", "FR" },
+ {"ZH", "IT" },
+ {"ZH", "KO" },
+
+
+ {"NO", "SV" },
+ {"NO", "FI" },
+ {"FI", "SV" },
+
+ {"PL", "FR" }, // Polish
+ {"PL", "RU" }, // Polish
+ {"PL", "HU" }, // Polish
+ {"PL", "ES" }, // Polish
+
+ */
+