See: Description
| Interface | Description |
|---|---|
| MatchingEngine |
Interface to a matcher which is responsible for matching the compiled glob pattern against the given input string.
|
| Class | Description |
|---|---|
| GlobPattern |
This class is responsible for compiling the given pattern into one of the Matching Engines.
|
import com.hrakaroo.glob.*;
// By default this will use '*' as the match-zero-or-more character, and '?' as the match-exactly-one character.
MatchingEngine m = GlobPattern.compile("*.txt");
for (String s : new String[]{"file.txt", "file.png"}) {
if (m.matches(s)) {
System.out.println("This is a text file: " + s);
}
}