Difference between revisions of "Extensions.StringUtil.MatchToRegularExpression"
Jump to navigation
Jump to search
Line 3: | Line 3: | ||
{{ClassificationActivity | MatchToRegularExpression | Uses of regular expressions | [[Term]] | [[StringUtil|OTX StringUtil extension]] | [[StringUtil related terms]] | [[OutOfBoundsException]] | - }} | {{ClassificationActivity | MatchToRegularExpression | Uses of regular expressions | [[Term]] | [[StringUtil|OTX StringUtil extension]] | [[StringUtil related terms]] | [[OutOfBoundsException]] | - }} | ||
− | == | + | == OTL Syntax == |
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;"> | <syntaxhighlight lang="java" enclose="div" style="font-size: medium;"> | ||
− | + | BooleanTerm = MatchToRegularExpression(StringTerm, StringTerm); | |
</syntaxhighlight> | </syntaxhighlight> | ||
Line 20: | Line 20: | ||
|} | |} | ||
− | == Examples == | + | == OTL Examples == |
<syntaxhighlight lang="java" enclose="div" style="font-size: medium;"> | <syntaxhighlight lang="java" enclose="div" style="font-size: medium;"> | ||
− | Boolean | + | Boolean Boolean1 = false; |
+ | |||
+ | Boolean1 = MatchToRegularExpression("emotive", "[a-z]*"); | ||
//Returns result = true | //Returns result = true | ||
</syntaxhighlight> | </syntaxhighlight> |
Revision as of 10:32, 10 February 2015
Contents
Classification
Name | MatchToRegularExpression |
Short Description | Uses of regular expressions |
Class | Term |
Extension | OTX StringUtil extension |
Group | StringUtil related terms |
Exceptions | OutOfBoundsException |
Checker Rules | - |
Standard Compliant | Yes |
OTL Syntax
BooleanTerm = MatchToRegularExpression(StringTerm, StringTerm);
Description
The MatchToRegularExpression term returns TRUE if the used regular expression also returns TRUE on the string .
Return Value
The Term returns the value, see table below.
![]()
In OTX, Terms are categorized according to its return data type!
Data Type | Description |
Boolean | Result of the regular expression that is applied to the string |
Properties
Name | Data Type | Class | Default | Cardinality | Description |
String | String | Term | - | [1] | The string is analysed |
RegExp | String | Term | - | [1] | The regular expression specified string will be carried out on the |
OTL Examples
Boolean Boolean1 = false;
Boolean1 = MatchToRegularExpression("emotive", "[a-z]*");
//Returns result = true
See also
ReplaceSubString
StringConcatenate
SubString
LengthOfString
IndexOf
SplitString
ToUpper
ToLower
Encode
Decode