static boolean matchAny(Collection patterns, S s, Matches m) { for (S pattern : patterns) if (match(pattern, s, m)) ret true; ret false; } static boolean matchAny(Collection patterns, S s) { ret matchAny(patterns, s, null); } // 2nd version sbool matchAny(S pat, Iterable l) { ret matchAny(pat, l, null); } sbool matchAny(S pat, Iterable l, Matches m) { if (l != null) for (S s : l) if (match(pat, s, m)) true; false; }