Capture
Definition
Namespace: Corvus.Ecma262.RegularExpressions
Assembly: Corvus.Regex.Ecma262.dll
Source: Capture.cs
A piece of the input text that a match or a group captured.
public class Capture
Inheritance
Object → Capture
Properties
| Property | Type | Description |
|---|---|---|
| Index | int |
Gets the position of the piece in the input, in UTF-16 code units. 0 for a group that did not take part. |
| Length | int |
Gets the length of the piece, in UTF-16 code units. 0 for a group that did not take part. |
| Value | string |
Gets the piece. The empty string for a group that did not take part. |
| ValueSpan | ReadOnlySpan<char> |
Gets the piece as a span of the input, allocating nothing. |
Methods
| Method | Description |
|---|---|
| ToString() | The piece. |
Applies To
| Product | Versions |
|---|---|
| .NET | 9, 10 |
| .NET Standard | 2.0, 2.1 |
Collaborate with us on GitHub
The source for this content can be found on GitHub, where you can also create and review issues and pull requests.
Open an issue