In This Article

ISearchPatternProvider Interface

Provides the base requirements for an object that can provide regular expression find/replace patterns based on a supplied pattern.

public interface ISearchPatternProvider : IKeyedObject

Remarks

All find/replace operations are performed using the built-in regular expression engine. This interface allows for the creation of custom pattern formats and enables them to be converted to the core regular expression pattern syntax.

Properties

Description

Gets the description of the search pattern provider.

string Description { get; }

Property Value

string:

The description of the search pattern provider.

RequiresCaseSensitivity

Gets whether this pattern requires case sensitivity.

bool RequiresCaseSensitivity { get; }

Property Value

bool:

true if this pattern requires case sensitivity; otherwise, false.

Methods

GetFindPattern(string)

Returns the regular expression match pattern to use for find operations, based on the supplied pattern that uses this provider.

string GetFindPattern(string pattern)
Parameter Type Description
pattern string

The pattern to convert using this provider.

Returns

string:

The regular expression match pattern to use for find operations.

GetReplacePattern(string)

Returns the regular expression match pattern to use for replace operations, based on the supplied pattern that uses this provider.

string GetReplacePattern(string pattern)
Parameter Type Description
pattern string

The pattern to convert using this provider.

Returns

string:

The regular expression match pattern to use for replace operations.

Inherited Members