Class StringMatchHelper
Determines whether the values match according to it's match type
Inheritance
Namespace: EPiServer.Personalization.VisitorGroups
Assembly: EPiServer.Cms.AspNetCore.dll
Version: 12.0.3Syntax
public static class StringMatchHelper : Object
Methods
GetMatchOptions()
Gets the match options.
Declaration
public static IEnumerable<SelectListItem> GetMatchOptions()
Returns
Type | Description |
---|---|
System. |
GetMatchOptions(MatchStringType)
Gets the match options.
Declaration
public static IEnumerable<SelectListItem> GetMatchOptions(MatchStringType selectedMatchType)
Parameters
Type | Name | Description |
---|---|---|
Match |
selectedMatchType | Type of the selected match. |
Returns
Type | Description |
---|---|
System. |
GetMatchOptions(MatchStringType, LocalizationService)
Gets the match options.
Declaration
public static IEnumerable<SelectListItem> GetMatchOptions(MatchStringType selectedMatchType, LocalizationService localizationService)
Parameters
Type | Name | Description |
---|---|---|
Match |
selectedMatchType | Type of the selected match. |
Localization |
localizationService | The resource locator that should be used by the method to get localized strings. |
Returns
Type | Description |
---|---|
System. |
GetMatchStringType(String)
Gets the match string type from a string value.
Declaration
public static MatchStringType GetMatchStringType(string matchStringType)
Parameters
Type | Name | Description |
---|---|---|
System. |
matchStringType | Type of the match as string. |
Returns
Type | Description |
---|---|
Match |
IsMatch(String, String, MatchStringType)
Matches the value in a criteria with the value in a setting depending on the matchtype.
Declaration
public static bool IsMatch(string criteriaValue, string settingsValue, MatchStringType matchType)
Parameters
Type | Name | Description |
---|---|---|
System. |
criteriaValue | The value from the criteria. |
System. |
settingsValue | The value from the setting. |
Match |
matchType | How to perform the match. |
Returns
Type | Description |
---|---|
System. |
|
IsMatch(String, String, String)
Matches the value in a criteria with the value in a setting depending on the matchtype.
Declaration
public static bool IsMatch(string criteriaValue, string settingsValue, string matchType)
Parameters
Type | Name | Description |
---|---|---|
System. |
criteriaValue | The value from the criteria. |
System. |
settingsValue | The value from the setting. |
System. |
matchType | How to perform the match. |
Returns
Type | Description |
---|---|
System. |
|