matches(of:)
Returns a collection containing all matches of the specified regex.
- iOS
- 16.0+
- macOS
- 13.0+
- tvOS
- 16.0+
- watchOS
- 9.0+
func matches<Output>(of r: some RegexComponent) -> [Regex<Output>.Match]
Parameters
- regex
The regex to search for.
Returns
A collection of matches of regex
.