how to convert string representation of regular expression to automaton with java?
is there any way to convert the string representa开发者_如何学编程tion of a regular expression into automaton with java?
You mean something like this?
Pattern p = Pattern.compile("a*b");
Matcher m = p.matcher("aaaaab");
boolean b = m.matches();
See details at http://download.oracle.com/javase/1.5.0/docs/api/java/util/regex/Pattern.html
精彩评论