Regex.Matches メソッド

入力文字列内で正規表現と一致する対象をすべて検索し、 Match が繰り返し呼び出された場合と同じように、連続して見つかった対象をすべて返します。

オーバーロードの一覧

指定した入力文字列内で、正規表現と一致する対象をすべて検索します。

.NET Compact Framework でもサポート。

[Visual Basic] Overloads Public Function Matches(String) As MatchCollection

[C#] public MatchCollection Matches(string);

[C++] public: MatchCollection* Matches(String*);

[JScript] public function Matches(String) : MatchCollection;

入力文字列内の指定した位置から検索を開始した場合に、その入力文字列内で正規表現と一致する対象をすべて検索します。

.NET Compact Framework でもサポート。

[Visual Basic] Overloads Public Function Matches(String, Integer) As MatchCollection

[C#] public MatchCollection Matches(string, int);

[C++] public: MatchCollection* Matches(String*, int);

[JScript] public function Matches(String, int) : MatchCollection;

指定した入力文字列内で、 pattern パラメータで指定された正規表現に一致する対象をすべて検索します。

.NET Compact Framework でもサポート。

[Visual Basic] Overloads Public Shared Function Matches(String, String) As MatchCollection

[C#] public static MatchCollection Matches(string, string);

[C++] public: static MatchCollection* Matches(String*, String*);

[JScript] public static function Matches(String, String) : MatchCollection;

options パラメータに一致オプションを指定し、指定した入力文字列内で、 pattern パラメータに指定した正規表現に一致する対象をすべて検索します。

.NET Compact Framework でもサポート。

[Visual Basic] Overloads Public Shared Function Matches(String, String, RegexOptions) As MatchCollection

[C#] public static MatchCollection Matches(string, string, RegexOptions);

[C++] public: static MatchCollection* Matches(String*, String*, RegexOptions);

[JScript] public static function Matches(String, String, RegexOptions) : MatchCollection;

参照

Regex クラス | Regex メンバ | System.Text.RegularExpressions 名前空間