Since version 2.6.0 it is possible to temporarily store values through functions. Stored values can easily be retrieved or referenced later in the same expression.

Functions used to retrieve (get) values previously stored (set) can directly be used in the same expression.

The values can only be used for the current expression and cannot be reused in another expression.

Expressions


FunctionReturned value
setBoolean(string variable_name, boolean value) : boolean

Creates a variable named variable_name for storing a boolean value, and assigns it a value, which is also returned in order to be used within an expression.

Example: setBoolean("myBoolean",true)

getBoolean(string variable_name) : boolean

Returns the value stored in a boolean variable named variable_name, which was previously created using the setBoolean() function.

Example: getBoolean("myBoolean")

setNumber(string variable_name, number value) : number

Creates a variable named variable_name for storing a number, and assigns it a value, which is also returned in order to be used within an expression.

Example: setNumber("myNumber",100)

getNumber(string variable_name) : number

Returns the value stored in a numeric variable named variable_name, which was previously created using the setNumber() function.

Example: getNumber("myNumber")

setString(string variable_name, string value) : string

Creates a variable named variable_name for storing a string, and assigns it a value, which is also returned in order to be used within an expression.

Example: setString("myString","Hello World!")

getString(string variable_name) : string

Returns the value stored in string variable named variable_name, which was previously created using the setString() function.

Example: getString("myString")

setNumberList(string variable_name, number list value) : number list

Creates a variable named variable_name for storing a number list, and assigns it a value, which is also returned in order to be used within an expression.

Example: setNumberList("myNumberList",[1,2,3])

getNumberList(string variable_name) : number list

Returns the value stored in number list variable named variable_name, which was previously created using the setNumberList() function.

Example: getNumberList("myNumberList")

setStringList(string variable_name, string list value) : string list

Creates a variable named variable_name for storing a string list, and assigns it a value, which is also returned in order to be used within an expression.

Example: setStringList("myStringList",["Hello","World"])

getStringList(string variable_name) : string list

Returns the value stored in string list variable named variable_name, which was previously created using the setStringList() function.

Example: getStringList("myStringList")

setIssueList(string variable_name, issue list value) : issue list

Creates a variable named variable_name for storing an issue list, and assigns it a value, which is also returned in order to be used within an expression.

Example: setIssueList("myIssueList",["KEY-1","KEY-2"])

getIssueList(string variable_name) : issue list

Returns the value stored in issue list variable named variable_name, which was previously created using setIssueList() function.

Example: getIssueList("myIssueList")



Example

You want to emphasize the importance of blocking issues by returning AND coloring the number of linked blocking issues.

If more than 3 issues are linked as blocking issues the exact number will be returned in red otherwise in green.

The number will directly be saved (set) and later referenced as x via the set/get method/function. 


Before value storageAfter value storage
count(linkedIssues("is blocked by")) > 3
"<font color=\"red\">" + count(linkedIssues("is blocked by"))  + "</font>"
: "<font color=\"green\">" + count(linkedIssues("is blocked by"))  + "</font>"

setNumber("x", count(linkedIssues("is blocked by")) > 3

? "<font color=\"red\">" + getNumber("x") + "</font>"

: "<font color=\"green\">" + getNumber("x") + "</font>"