Regex.Count 메서드
정의
중요
일부 정보는 릴리스되기 전에 상당 부분 수정될 수 있는 시험판 제품과 관련이 있습니다. Microsoft는 여기에 제공된 정보에 대해 어떠한 명시적이거나 묵시적인 보증도 하지 않습니다.
오버로드
| Name | Description |
|---|---|
| Count(ReadOnlySpan<Char>) |
정규식의 모든 발생에 대한 입력 범위를 검색하고 일치 항목 수를 반환합니다. |
| Count(String) |
입력 문자열에서 정규식의 모든 항목을 검색하고 일치 항목 수를 반환합니다. |
| Count(ReadOnlySpan<Char>, Int32) |
정규식의 모든 발생에 대한 입력 범위를 검색하고 일치 항목 수를 반환합니다. |
| Count(ReadOnlySpan<Char>, String) |
정규식의 모든 발생에 대한 입력 범위를 검색하고 일치 항목 수를 반환합니다. |
| Count(String, String) |
입력 문자열에서 정규식의 모든 항목을 검색하고 일치 항목 수를 반환합니다. |
| Count(ReadOnlySpan<Char>, String, RegexOptions) |
정규식의 모든 발생에 대한 입력 범위를 검색하고 일치 항목 수를 반환합니다. |
| Count(String, String, RegexOptions) |
입력 문자열에서 정규식의 모든 항목을 검색하고 일치 항목 수를 반환합니다. |
| Count(ReadOnlySpan<Char>, String, RegexOptions, TimeSpan) |
정규식의 모든 발생에 대한 입력 범위를 검색하고 일치 항목 수를 반환합니다. |
| Count(String, String, RegexOptions, TimeSpan) |
입력 문자열에서 정규식의 모든 항목을 검색하고 일치 항목 수를 반환합니다. |
Count(ReadOnlySpan<Char>)
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
정규식의 모든 발생에 대한 입력 범위를 검색하고 일치 항목 수를 반환합니다.
public:
int Count(ReadOnlySpan<char> input);
public int Count(ReadOnlySpan<char> input);
member this.Count : ReadOnlySpan<char> -> int
Public Function Count (input As ReadOnlySpan(Of Char)) As Integer
매개 변수
- input
- ReadOnlySpan<Char>
일치 항목을 검색할 범위입니다.
반환
일치 항목 수입니다.
적용 대상
Count(String)
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
입력 문자열에서 정규식의 모든 항목을 검색하고 일치 항목 수를 반환합니다.
public:
int Count(System::String ^ input);
public int Count(string input);
member this.Count : string -> int
Public Function Count (input As String) As Integer
매개 변수
- input
- String
일치 항목을 검색할 문자열입니다.
반환
일치 항목 수입니다.
예외
input
null.
적용 대상
Count(ReadOnlySpan<Char>, Int32)
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
정규식의 모든 발생에 대한 입력 범위를 검색하고 일치 항목 수를 반환합니다.
public:
int Count(ReadOnlySpan<char> input, int startat);
public int Count(ReadOnlySpan<char> input, int startat);
member this.Count : ReadOnlySpan<char> * int -> int
Public Function Count (input As ReadOnlySpan(Of Char), startat As Integer) As Integer
매개 변수
- input
- ReadOnlySpan<Char>
일치 항목을 검색할 범위입니다.
- startat
- Int32
검색을 시작할 문자 위치(0부터 시작)입니다.
반환
일치 항목 수입니다.
적용 대상
Count(ReadOnlySpan<Char>, String)
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
정규식의 모든 발생에 대한 입력 범위를 검색하고 일치 항목 수를 반환합니다.
public:
static int Count(ReadOnlySpan<char> input, System::String ^ pattern);
public static int Count(ReadOnlySpan<char> input, string pattern);
static member Count : ReadOnlySpan<char> * string -> int
Public Shared Function Count (input As ReadOnlySpan(Of Char), pattern As String) As Integer
매개 변수
- input
- ReadOnlySpan<Char>
일치 항목을 검색할 범위입니다.
- pattern
- String
일치시킬 정규식 패턴입니다.
반환
일치 항목 수입니다.
예외
정규식 구문 분석 오류가 발생했습니다.
적용 대상
Count(String, String)
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
입력 문자열에서 정규식의 모든 항목을 검색하고 일치 항목 수를 반환합니다.
public:
static int Count(System::String ^ input, System::String ^ pattern);
public static int Count(string input, string pattern);
static member Count : string * string -> int
Public Shared Function Count (input As String, pattern As String) As Integer
매개 변수
- input
- String
일치 항목을 검색할 문자열입니다.
- pattern
- String
일치시킬 정규식 패턴입니다.
반환
일치 항목 수입니다.
예외
input 또는 patternnull.
정규식 구문 분석 오류가 발생했습니다.
적용 대상
Count(ReadOnlySpan<Char>, String, RegexOptions)
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
정규식의 모든 발생에 대한 입력 범위를 검색하고 일치 항목 수를 반환합니다.
public:
static int Count(ReadOnlySpan<char> input, System::String ^ pattern, System::Text::RegularExpressions::RegexOptions options);
public static int Count(ReadOnlySpan<char> input, string pattern, System.Text.RegularExpressions.RegexOptions options);
static member Count : ReadOnlySpan<char> * string * System.Text.RegularExpressions.RegexOptions -> int
Public Shared Function Count (input As ReadOnlySpan(Of Char), pattern As String, options As RegexOptions) As Integer
매개 변수
- input
- ReadOnlySpan<Char>
일치 항목을 검색할 범위입니다.
- pattern
- String
일치시킬 정규식 패턴입니다.
- options
- RegexOptions
일치 옵션을 지정하는 열거형 값의 비트 조합입니다.
반환
일치 항목 수입니다.
예외
options
RegexOptions 값의 유효한 비트 조합이 아닙니다.
정규식 구문 분석 오류가 발생했습니다.
적용 대상
Count(String, String, RegexOptions)
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
입력 문자열에서 정규식의 모든 항목을 검색하고 일치 항목 수를 반환합니다.
public:
static int Count(System::String ^ input, System::String ^ pattern, System::Text::RegularExpressions::RegexOptions options);
public static int Count(string input, string pattern, System.Text.RegularExpressions.RegexOptions options);
static member Count : string * string * System.Text.RegularExpressions.RegexOptions -> int
Public Shared Function Count (input As String, pattern As String, options As RegexOptions) As Integer
매개 변수
- input
- String
일치 항목을 검색할 문자열입니다.
- pattern
- String
일치시킬 정규식 패턴입니다.
- options
- RegexOptions
일치 옵션을 지정하는 열거형 값의 비트 조합입니다.
반환
일치 항목 수입니다.
예외
input 또는 patternnull.
options RegexOptions 값의 유효한 비트 조합이 아닙니다.
정규식 구문 분석 오류가 발생했습니다.
적용 대상
Count(ReadOnlySpan<Char>, String, RegexOptions, TimeSpan)
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
정규식의 모든 발생에 대한 입력 범위를 검색하고 일치 항목 수를 반환합니다.
public:
static int Count(ReadOnlySpan<char> input, System::String ^ pattern, System::Text::RegularExpressions::RegexOptions options, TimeSpan matchTimeout);
public static int Count(ReadOnlySpan<char> input, string pattern, System.Text.RegularExpressions.RegexOptions options, TimeSpan matchTimeout);
static member Count : ReadOnlySpan<char> * string * System.Text.RegularExpressions.RegexOptions * TimeSpan -> int
Public Shared Function Count (input As ReadOnlySpan(Of Char), pattern As String, options As RegexOptions, matchTimeout As TimeSpan) As Integer
매개 변수
- input
- ReadOnlySpan<Char>
일치 항목을 검색할 범위입니다.
- pattern
- String
일치시킬 정규식 패턴입니다.
- options
- RegexOptions
일치 옵션을 지정하는 열거형 값의 비트 조합입니다.
- matchTimeout
- TimeSpan
제한 시간 간격 또는 메서드가 시간 초과되지 않아야 함을 나타내는 InfiniteMatchTimeout.
반환
일치 항목 수입니다.
예외
options
RegexOptions 값의 유효한 비트 조합이 아니거나 matchTimeout 음수, 0 또는 약 24일보다 큽니다.
정규식 구문 분석 오류가 발생했습니다.
적용 대상
Count(String, String, RegexOptions, TimeSpan)
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
- Source:
- Regex.Count.cs
입력 문자열에서 정규식의 모든 항목을 검색하고 일치 항목 수를 반환합니다.
public:
static int Count(System::String ^ input, System::String ^ pattern, System::Text::RegularExpressions::RegexOptions options, TimeSpan matchTimeout);
public static int Count(string input, string pattern, System.Text.RegularExpressions.RegexOptions options, TimeSpan matchTimeout);
static member Count : string * string * System.Text.RegularExpressions.RegexOptions * TimeSpan -> int
Public Shared Function Count (input As String, pattern As String, options As RegexOptions, matchTimeout As TimeSpan) As Integer
매개 변수
- input
- String
일치 항목을 검색할 문자열입니다.
- pattern
- String
일치시킬 정규식 패턴입니다.
- options
- RegexOptions
일치 옵션을 지정하는 열거형 값의 비트 조합입니다.
- matchTimeout
- TimeSpan
제한 시간 간격 또는 메서드가 시간 초과되지 않아야 함을 나타내는 InfiniteMatchTimeout.
반환
일치 항목 수입니다.
예외
input 또는 patternnull.
options RegexOptions 값의 유효한 비트 조합이 아니거나 matchTimeout 음수, 0 또는 약 24일보다 큽니다.
정규식 구문 분석 오류가 발생했습니다.