Text

Text manipulation library

contains(string, match)

does the string contain the match?

Parameters
Name Required Type Description

string

Yes

Text

match

Yes

Text

Returns

Boolean

Examples
contains("Trisotech", "iso") => true

contains("DMN", "Errors") => false

ends with(string, match)

does the string end with the match?

Parameters
Name Required Type Description

string

Yes

Text

match

Yes

Text

Returns

Boolean

Examples
ends with("Trisotech DMN", "Trisotech") => false

ends with("Trisotech DMN", "DMN") => true

lower case(string)

returns a lowercased string

Parameters
Name Required Type Description

string

Yes

Text

Returns

Text

Examples
lower case("Trisotech DMN") => "trisotech dmn"

lower case("TriSoTech_DMN") => "trisotech_dmn"

matches(input, pattern, [flags])

does the input match the regex pattern?

Parameters
Name Required Type Description

input

Yes

Text

pattern

Yes

Text

flags

No

Text

Returns

Boolean

Examples
matches("gray","gr[ae]y") => true

matches("grey", "gr[ae]y") => true

matches("foobar", "^fo*B", "i") => true

replace(input, pattern, replacement, [flags])

regular expression pattern matching and replacement

Parameters
Name Required Type Description

input

Yes

Text

pattern

Yes

Text

replacement

Yes

Text

flags

No

Text

Returns

Text

Examples
replace("Trisotech DMN", "DMN","BPMN") => "Trisotech BPMN"

replace("DMN", "D", "BP", "i") => "BPMN"

replace("Trisotech", "t", "B") => "Brisobech"

split(string, delimiter, [flags])

tokenize a string by separating it using the delimiter character.

Parameters
Name Required Type Description

string

Yes

Text

delimiter

Yes

Text

flags

No

Text

Returns

Collection of Text

Examples
split("Trisotech_DMN", "_") => ["Trisotech", "DMN"]

split("DMN BPMN CMMN", "M") => ["D", "N BP", "N C", "", "N"]

starts with(string, match)

does the string start with the match?

Parameters
Name Required Type Description

string

Yes

Text

match

Yes

Text

Returns

Boolean

Examples
starts with("Trisotech DMN", "Trisotech") => true

starts with("Trisotech DMN", "DMN") => false

string(from)

convert from to a string

Parameters
Name Required Type Description

from

Yes

non-null

Returns

Text

Examples
string(35.6) => "35.6"

string(null) => null

string(mask, p)

returns the formatted string by given mask and p arguments. Note that this function is not yet a standardized FEEL function.

Parameters
Name Required Type Description

mask

Yes

Text

p

Yes

Text

Returns

Text

Examples
string("Trisotech %s", "DMN") => Trisotech DMN

string("Trisotech %s and %s and %s", "BPMN", "DMN", "CMMN") => Trisotech BPMN and DMN and CMMN

string join(list, [delimiter])

return a string which is composed by joining all the string elements from the list parameter, separated by the delimiter.

Parameters
Name Required Type Description

list

Yes

list

delimiter

No

Text

Returns

Text

Examples
string join(["BPMN", "DMN", "CMMN"], "_and_") => "BPMN_and_DMN_and_CMMN"

string join(["a", "b", "c"], null) => "abc"

string join([], "X") => ""

string join(["Tri", "so", "tech"]) => "Trisotech"

string join(["Trisotech", null, " DMN"]) => "Trisotech DMN"

string length(string)

returns length of string

Parameters
Name Required Type Description

string

Yes

Text

Returns

Number

Examples
string length("Trisotech DMN") => 13

string length("DMN") => 3

substring(string, start position, [length])

returns length (or all) characters in string, starting at start position. First position is 1, last position is -1

Parameters
Name Required Type Description

string

Yes

Text

start position

Yes

Number

length

No

Number

Returns

Text

Examples
substring("Trisotech DMN", 11) => "DMN"

substring("Trisotech DMN", 6, 4) => "tech"

substring("Trisotech DMN", -11, -3) => "iso"

substring after(string, match)

returns the substring of string after the match in the string

Parameters
Name Required Type Description

string

Yes

Text

match

Yes

Text

Returns

Text

Examples
substring after("Trisotech DMN", "Trisotech ") => "DMN"

substring after("Trisotech DMN", "abc") => ""

substring before(string, match)

returns the substring of string before the match in the string

Parameters
Name Required Type Description

string

Yes

Text

match

Yes

Text

Returns

Text

Examples
substring before("Trisotech DMN", "DMN") => "Trisotech "

substring before("Trisotech DMN", "abc") => ""

upper case(string)

returns an uppercased string

Parameters
Name Required Type Description

string

Yes

Text

Returns

Text

Examples
upper case("Trisotech DMN") => "TRISOTECH DMN"

upper case("3sotech DMN 2017") => "3SOTECH DMN 2017"