List of utility methods to do Regex Compile
String[] | regexCompile(String regex, String str) regex Compile String[] strs = new String[0]; Pattern p = Pattern.compile(regex); Matcher m = p.matcher(str); if (m.find() && m.groupCount() > 0) { strs = new String[m.groupCount()]; for (int i = 0; i < m.groupCount(); i++) { strs[i] = m.group(i + 1); return strs; |