Example 7: Extracting information from a log file

In this example, we are going to use actual output from an Android adb debugging session. Your goal is to use any regular expression techniques that we've learned so far to extract the filename, method name and line number of line of the stack trace (they follow the form "at package.class.methodname(filename:linenumber)").

Good luck!

your task text capture result
skip text W/dalvikvm( 1553): threadid=1: uncaught exception ?
skip text E/( 1553): FATAL EXCEPTION: main ?
skip text E/( 1553): java.lang.StringIndexOutOfBoundsException ?
capture text E/( 1553): at widget.List.makeView(ListView.java:1727) makeView, ListView.java, 1727 ?
capture text E/( 1553): at widget.List.fillDown(ListView.java:652) fillDown, ListView.java, 652 ?
capture text E/( 1553): at widget.List.fillFrom(ListView.java:709) fillFrom, ListView.java, 709 ?
Solution This one can be tricky too, but we really just want to capture the method name, filename, and line number. This can be achieved using the expression '(\w+)\(([\w.]+):(\d+)\)' in which the first capture group is the method, followed by an escaped parenthesis, followed by the filename, a colon, and finally the line number.
Solve the above task to continue on to the next problem, or read the Solution.