Cm5StringStream.match method
Cm5StringStream › match
Unofficial
Matches against a string or regular expression pattern.Signature:
match(pattern: string, consume?: boolean | undefined, caseFold?: boolean | undefined): booleanParameters:
| Parameter | Type | Description |
|---|---|---|
| pattern | string | The string pattern to match. |
| consume? | boolean | undefined | Whether to advance the stream on match. |
| caseFold? | boolean | undefined | Whether to match case-insensitively. |
Returns: boolean — true if the pattern matched.
Unofficial
Matches against a regular expression pattern.Signature:
match(pattern: RegExp, consume?: boolean | undefined): null | string[]Parameters:
| Parameter | Type | Description |
|---|---|---|
| pattern | RegExp | The regular expression to match. |
| consume? | boolean | undefined | Whether to advance the stream on match. |
Returns: null | string[] — The match array, or null if no match.