This splits strings of the form "x=y,v=w" into distinct components and puts them into a map. In the case of a string like "x,y=z" then x is loaded with the empty string. @param str @return
(String str)
| 429 | * @return |
| 430 | */ |
| 431 | private static Map<String, Object> splitConfig(String str) { |
| 432 | HashMap<String, Object> options = new HashMap<>(); |
| 433 | String[] splits = str.split(","); |
| 434 | for (String s : splits) { |
| 435 | String[] p = s.split("="); |
| 436 | options.put(p[0], parseValue(p[1])); |
| 437 | } |
| 438 | return options; |
| 439 | } |
| 440 | |
| 441 | private static Object parseValue(String str) { |
| 442 | if(str.equals("true")) { |