RegexRunner.Scan 方法
定义
由 CompileToAssembly 方法生成的 Regex 对象使用。Used by a Regex object generated by the CompileToAssembly method.
重载
| Scan(Regex, String, Int32, Int32, Int32, Int32, Boolean) |
此 API 支持产品基础结构,不能在代码中直接使用。 由 CompileToAssembly 方法生成的 Regex 对象使用。Used by a Regex object generated by the CompileToAssembly method. |
| Scan(Regex, String, Int32, Int32, Int32, Int32, Boolean, TimeSpan) |
此 API 支持产品基础结构,不能在代码中直接使用。 由 CompileToAssembly 方法生成的 Regex 对象使用。Used by a Regex object generated by the CompileToAssembly method. |
Scan(Regex, String, Int32, Int32, Int32, Int32, Boolean)
由 CompileToAssembly 方法生成的 Regex 对象使用。Used by a Regex object generated by the CompileToAssembly method.
此 API 支持产品基础结构,不能在代码中直接使用。
protected public:
System::Text::RegularExpressions::Match ^ Scan(System::Text::RegularExpressions::Regex ^ regex, System::String ^ text, int textbeg, int textend, int textstart, int prevlen, bool quick);
protected internal System.Text.RegularExpressions.Match? Scan (System.Text.RegularExpressions.Regex regex, string text, int textbeg, int textend, int textstart, int prevlen, bool quick);
protected internal System.Text.RegularExpressions.Match Scan (System.Text.RegularExpressions.Regex regex, string text, int textbeg, int textend, int textstart, int prevlen, bool quick);
member this.Scan : System.Text.RegularExpressions.Regex * string * int * int * int * int * bool -> System.Text.RegularExpressions.Match
Protected Friend Function Scan (regex As Regex, text As String, textbeg As Integer, textend As Integer, textstart As Integer, prevlen As Integer, quick As Boolean) As Match
参数
- regex
- Regex
正则表达式引擎的实例。An instance of the regular expression engine.
- text
- String
要扫描模式匹配的文本。The text to scan for a pattern match.
- textbeg
- Int32
text 中从零开始的起始位置(正则表达式引擎在此位置扫描匹配项)。The zero-based starting position in text at which the regular expression engine scans for a match.
- textend
- Int32
text 中从零开始的终点位置(正则表达式引擎在此位置扫描匹配项)。The zero-based ending position in text at which the regular expression engine scans for a match.
- textstart
- Int32
此匹配项要扫描的从零开始的起始位置。The zero-based starting position to scan for this match.
- prevlen
- Int32
上一个匹配项中的字符数。The number of characters in the previous match.
- quick
- Boolean
若要在快速模式下搜索匹配项,则为 true;否则为 false。true to search for a match in quick mode; otherwise, false.
返回
匹配项。A match.
适用于
Scan(Regex, String, Int32, Int32, Int32, Int32, Boolean, TimeSpan)
由 CompileToAssembly 方法生成的 Regex 对象使用。Used by a Regex object generated by the CompileToAssembly method.
此 API 支持产品基础结构,不能在代码中直接使用。
protected public:
System::Text::RegularExpressions::Match ^ Scan(System::Text::RegularExpressions::Regex ^ regex, System::String ^ text, int textbeg, int textend, int textstart, int prevlen, bool quick, TimeSpan timeout);
protected internal System.Text.RegularExpressions.Match? Scan (System.Text.RegularExpressions.Regex regex, string text, int textbeg, int textend, int textstart, int prevlen, bool quick, TimeSpan timeout);
protected internal System.Text.RegularExpressions.Match Scan (System.Text.RegularExpressions.Regex regex, string text, int textbeg, int textend, int textstart, int prevlen, bool quick, TimeSpan timeout);
member this.Scan : System.Text.RegularExpressions.Regex * string * int * int * int * int * bool * TimeSpan -> System.Text.RegularExpressions.Match
Protected Friend Function Scan (regex As Regex, text As String, textbeg As Integer, textend As Integer, textstart As Integer, prevlen As Integer, quick As Boolean, timeout As TimeSpan) As Match
参数
- regex
- Regex
正则表达式引擎的实例。An instance of the regular expression engine.
- text
- String
要扫描模式匹配的文本。The text to scan for a pattern match.
- textbeg
- Int32
text 中从零开始的起始位置(正则表达式引擎在此位置扫描匹配项)。The zero-based starting position in text at which the regular expression engine scans for a match.
- textend
- Int32
text 中从零开始的终点位置(正则表达式引擎在此位置扫描匹配项)。The zero-based ending position in text at which the regular expression engine scans for a match.
- textstart
- Int32
此匹配项要扫描的从零开始的起始位置。The zero-based starting position to scan for this match.
- prevlen
- Int32
上一个匹配项中的字符数。The number of characters in the previous match.
- quick
- Boolean
若要在快速模式下搜索匹配项,则为 true;否则为 false。true to search for a match in quick mode; otherwise, false.
- timeout
- TimeSpan
超时时间间隔。The timeout interval.
返回
匹配项。A match.