String candidate = "this is a test, A TEST.";
String regex = "[a-zA-Z]+";
Pattern p = Pattern.compile(regex);
Matcher m = p.matcher(candidate);