public static boolean simpleMatch(String[] patterns,String str){
  if (patterns != null) {
    for (    String pattern : patterns) {
      if (simpleMatch(pattern,str)) {
        return true;
      }
    }
  }
  return false;
}

public static boolean simpleMatch ( String [ ] patterns , String str ) { if ( patterns != null ) { for ( String pattern : patterns ) { if ( simpleMatch ( pattern , str ) ) { return true ; } } } return false ; }
match a string against the given patterns , supporting the following simple pattern styles : " xxx * " , " * xxx " , " * xxx * " and " xxx * yyy " matches ( with an arbitrary number of pattern parts ) , as well as direct equality .
