01: package abbot.finder.matchers;
02:
03: import abbot.finder.Matcher;
04: import abbot.util.ExtendedComparator;
05:
06: /** Convenience abstract class to provide regexp-based matching of strings. */
07: public abstract class AbstractMatcher implements Matcher {
08: /** Provides direct or regexp matching. To match a regular expression,
09: bound the expected string with slashes, e.g. /regular expression/.
10: */
11: protected boolean stringsMatch(String expected, String actual) {
12: return ExtendedComparator.stringsMatch(expected, actual);
13: }
14:
15: public String toString() {
16: return getClass().getName();
17: }
18: }
|