/ Published in: Java
                    
                                        
                            
                                Expand |
                                Embed | Plain Text
                            
                        
                        Copy this code and paste it in your HTML
 import java.util.regex.Matcher; import java.util.regex.Pattern; // Java -has- issues { Pattern pattern = Pattern.compile(regexp); Matcher matcher = pattern.matcher(string); boolean matchFound = matcher.find(); if( matchFound ) { for( int i = 0; i <= matcher.groupCount(); i++ ) { matches[i] = matcher.group(i); } } return matches; }
Comments
                    Subscribe to comments
                
                