Example
In this example, we will pass the required parameters to the function transformation object using a Variables object.
Where,
pattern = {x,y}
str = 1234{x,y}
startAt = 4
In the output window, you can see that Astera has returned “True”, as the specified string matches the specified pattern value, from the specified start position.
Name
IsMatchRegEx
Syntax
IsMatchRegEx (String pattern, String str, Integer startAt)
Purpose
To return true if the regular expression found a match in the string. Otherwise, returns false. It also considers the starting position.
Description
Indicates whether the regular expression finds a match in a specified input string value at the specified integer position.
Return Type
Boolean
Parameters
pattern [System.String] – Regular expression pattern to match
str [System.String] – String to search for a match
startAt [System.Int64] – The character position from which to start the search