public class WildcharUtils extends Object
This method uses recursive matching, as in linux or windows. regexp works the same. This method is very fast, comparing to similar implementations.
| Constructor and Description |
|---|
WildcharUtils() |
| Modifier and Type | Method and Description |
|---|---|
static boolean |
match(String string,
String pattern)
Checks whether a string matches a given wildcard pattern.
|
static int |
matchOne(String src,
String[] patterns)
Matches string to at least one pattern.
|
public static boolean match(String string, String pattern)
string - input stringpattern - pattern to matchtrue if string matches the pattern, otherwise falsepublic static int matchOne(String src, String[] patterns)
-1 otherwise.match(String, String)Copyright © 2016 jetbrick. All rights reserved.