List<String> (String[] args, String paramName) { List<String> result = new ArrayList<>(); String prefix = paramName + '='; for (String param : args) { if (param.startsWith(prefix)) { StringTokenizer tokenizer = new StringTokenizer(param.substring(prefix.length()), ";"); while (tokenizer.hasMoreTokens()) { result.add(tokenizer.nextToken()); } } } return result; }