question: public String [ ] match ( String text ) { List < String > matches = new ArrayList < String > ( ) ; _match ( text , matches ) ; String arr [ ] = new String [ matches . size ( ) ] ; for ( int i = 0 ; i < matches . size ( ) ; i ++ ) arr [ i ] = matches . get ( i ) ; return arr ; }
target:  This method is borrowed from the JavaScript RegExp object. It parses a string and returns as an array any assignments to parenthesis groups in the pattern's regular expression