String pattern = "(\\d\\d)-(\\d\\d)-(\\d\\d\\d\\d)";
String test = "05-10-1977";
_assert(Pattern.matches(pattern, test));
GWT.log("Patter.match(String)", null);
Pattern regExp = new Pattern(pattern);
String[] parts = regExp.match(test);
_assert(parts[1].equals("05"));
_assert(parts[2].equals("10"));
_assert(parts[3].equals("1977"));
GWT.log("Patter.pattern()", null);
_assert(regExp.pattern().equals(pattern));
GWT.log("Patter.split(String)", null);
regExp = new Pattern("-");
parts = regExp.split(test);
_assert(parts[0].equals("05"));
_assert(parts[1].equals("10"));
}