Share via


TextFilterRule.GetRegexPattern(String, String) Method

Definition

Gets a regular expression pattern based on the current value and the specified patterns. If the current value is an exact-match string, exactMatchPattern will be used; otherwise, pattern will be used.

protected public:
 System::String ^ GetRegexPattern(System::String ^ pattern, System::String ^ exactMatchPattern);
protected public:
 Platform::String ^ GetRegexPattern(Platform::String ^ pattern, Platform::String ^ exactMatchPattern);
std::wstring GetRegexPattern(std::wstring const & pattern, std::wstring const & exactMatchPattern);
protected internal string GetRegexPattern (string pattern, string exactMatchPattern);
member this.GetRegexPattern : string * string -> string
Protected Friend Function GetRegexPattern (pattern As String, exactMatchPattern As String) As String

Parameters

pattern
String

The pattern to use if the current value is not an exact-match string. The pattern must contain a {0} token.

exactMatchPattern
String

The pattern to use if the current value is an exact-match string. The pattern must contain a {0} token.

Returns

A regular expression pattern based on the current value and the specified patterns.

Exceptions

The specified value is a null reference.

Applies to