MCPcopy Create free account
hub / github.com/5zig/The-5zig-Mod / deserialize

Method deserialize

The 5zig Mod/src/eu/the5zig/mod/I18n.java:225–232  ·  view source on GitHub ↗
(String file)

Source from the content-addressed store, hash-verified

223 }
224
225 public static Locale deserialize(String file) {
226 String[] args = file.split("_");
227 if (args.length != 3)
228 return null;
229 if (!args[0].equals(MID))
230 return null;
231 return new Locale(args[1].toLowerCase(Locale.ROOT), args[2].toUpperCase());
232 }
233
234 public static String serialize(Locale locale) {
235 return PRE + MID + "_" + locale.toString() + END;

Callers 3

loadLocalesMethod · 0.95
downloadUpdateMethod · 0.95
getLocalesMethod · 0.95

Calls 1

equalsMethod · 0.45

Tested by

no test coverage detected