Import std.text.glob
Glob
class
Public Class Glob
A pattern, read once, which Matches tells text against.
Examples
Expect(Glob.Match("*.txt", "notes.txt"))
Expect(!Glob.Match("*.txt", "notes.md"))
Local images = Glob("img?.[pj]ng")
Expect(images.Matches("img1.png") && images.Matches("img2.jng") && !images.Matches("img10.png"))
Expect(Glob.Match("READ*", "readme", True))-
The pattern, as it was given.
-
Whether letters match in either case.
-
A Glob of
pattern. WithignoreCase, letters match in either case, as Unicode folds each one, so thepatternmatches all it does without it, and more. -
Whether all of
textmatches the pattern. -
Public Static Method Match(pattern: String, text: String, ignoreCase: Bool = False): Boolstatic method #Whether all of
textmatchespattern, as Glob(pattern,ignoreCase).Matches(text) tells.
Report an issue with this page or with FutureBlitz on GitHub.