1 import "JavaBuiltin" as Java
\r
3 importJava "java.util.regex.Pattern" where
\r
6 compile :: String -> Pattern
\r
7 matcher :: Pattern -> String -> <Proc> Matcher
\r
9 importJava "java.util.regex.Matcher" where
\r
12 matches :: Matcher -> <Proc> Boolean
\r
14 doMatch pattern text = matches (matcher pattern text)
\r
16 main = doMatch (compile ".*xxx.*") "fffxxooxxxlll"
\r