diff --git a/src/builtins/camunda.json b/src/builtins/camunda.json index 26b0f3e..746d9fd 100644 --- a/src/builtins/camunda.json +++ b/src/builtins/camunda.json @@ -49,7 +49,7 @@ }, { "name": "number(from)", - "description": "
Parses the given string to a number.
\nFunction signature
\nnumber(from: string): number\n
\nExamples
\nnumber("1500.5")\n// 1500.5\n
\n"
+ "description": "Parses the given string to a number.
\nReturns null
if the string is not a number.
Function signature
\nnumber(from: string): number\n
\nExamples
\nnumber("1500.5")\n// 1500.5\n
\n"
},
{
"name": "context(entries)",
@@ -57,11 +57,11 @@
},
{
"name": "date(from)",
- "description": "Returns a date from the given value.
\nFunction signature
\ndate(from: string): date\n
\nParses the given string into a date.
\ndate(from: date and time): date\n
\nExtracts the date component from the given date and time.
\nExamples
\ndate("2018-04-29")\n// date("2018-04-29")\n\ndate(date and time("2012-12-25T11:00:00"))\n// date("2012-12-25")\n
\n"
+ "description": "Returns a date from the given value.
\nReturns null
if the string is not a valid calendar date. For example, "2024-06-31"
is invalid because June has\nonly 30 days.
Function signature
\ndate(from: string): date\n
\nParses the given string into a date.
\ndate(from: date and time): date\n
\nExtracts the date component from the given date and time.
\nExamples
\ndate("2018-04-29")\n// date("2018-04-29")\n\ndate(date and time("2012-12-25T11:00:00"))\n// date("2012-12-25")\n
\n"
},
{
"name": "date(year, month, day)",
- "description": "Returns a date from the given components.
\nFunction signature
\ndate(year: number, month: number, day: number): date\n
\nExamples
\ndate(2012, 12, 25)\n// date("2012-12-25")\n
\n"
+ "description": "Returns a date from the given components.
\nReturns null
if the components don't represent a valid calendar date. For example, 2024,6,31
is invalid because\nJune has only 30 days.
Function signature
\ndate(year: number, month: number, day: number): date\n
\nExamples
\ndate(2012, 12, 25)\n// date("2012-12-25")\n
\n"
},
{
"name": "time(from)",
@@ -77,7 +77,7 @@
},
{
"name": "date and time(from)",
- "description": "Parses the given string into a date and time.
\nFunction signature
\ndate and time(from: string): date and time\n
\nExamples
\ndate and time("2018-04-29T09:30:00")\n// date and time("2018-04-29T09:30:00")\n
\n"
+ "description": "Parses the given string into a date and time.
\nReturns null
if the string is not a valid calendar date. For example, "2024-06-31T10:00:00"
is invalid because\nJune has only 30 days.
Function signature
\ndate and time(from: string): date and time\n
\nExamples
\ndate and time("2018-04-29T09:30:00")\n// date and time("2018-04-29T09:30:00")\n
\n"
},
{
"name": "date and time(date, time)",
@@ -207,6 +207,14 @@
"name": "string join(list, delimiter, prefix, suffix)",
"description": "Camunda Extension
\nJoins a list of strings into a single string. This is similar to\nJava's joining\nfunction.
\nIf an item of the list is null
, the item is ignored for the result string. If an item is\nneither a string nor null
, the function returns null
instead of a string.
The resulting string starts with prefix
, contains a delimiter
between each element, and ends\nwith suffix
.
Function signature
\nstring join(list: list<string>, delimiter: string, prefix: string, suffix: string): string\n
\nExamples
\nstring join(["a","b","c"], ", ", "[", "]")\n// "[a, b, c]"\n
\n"
},
+ {
+ "name": "is empty(list)",
+ "description": "Camunda Extension
\nReturns true
if the given list is empty. Otherwise, returns false
.
Function signature
\nis empty(list: list): boolean\n
\nExamples
\nis empty([])\n// true\n\nis empty([1,2,3])\n// false\n
\n"
+ },
+ {
+ "name": "partition(list, size)",
+ "description": "Camunda Extension
\nReturns consecutive sublists of a list, each of the same size (the final list may be smaller).
\nIf size
is less than 0
, it returns null
.
Function signature
\npartition(list: list, size: number): list\n
\nExamples
\npartition([1,2,3,4,5], 2)\n// [[1,2], [3,4], [5]]\n\npartition([], 2)\n// []\n\npartition([1,2], 0)\n// null\n
\n"
+ },
{
"name": "decimal(n, scale)",
"description": "Rounds the given value at the given scale.
\nFunction signature
\ndecimal(n: number, scale: number): number\n
\nExamples
\ndecimal(1/3, 2)\n// .33\n\ndecimal(1.5, 0)\n// 2\n
\n"
@@ -385,11 +393,11 @@
},
{
"name": "substring(string, start position)",
- "description": "Returns a substring of the given value starting at start position
.
Function signature
\nsubstring(string: string, start position: number): string\n
\nThe start position
starts at the index 1
. The last position is -1
.
Examples
\nsubstring("foobar", 3)\n// "obar"\n
\n"
+ "description": "Returns a substring of the given value starting at start position
.
Function signature
\nsubstring(string: string, start position: number): string\n
\nThe start position
starts at the index 1
. The last position is -1
.
Examples
\nsubstring("foobar", 3)\n// "obar"\n\nsubstring("foobar", -2)\n// "ar"\n
\n"
},
{
"name": "substring(string, start position, length)",
- "description": "Returns a substring of the given value starting at start position
.
Function signature
\nsubstring(string: string, start position: number, length: number): string\n
\nThe start position
starts at the index 1
. The last position is -1
.
Examples
\nsubstring("foobar", 3, 3)\n// "oba"\n
\n"
+ "description": "Returns a substring of the given value, starting at start position
with the given length
. If length
is greater than\nthe remaining characters of the value, it returns all characters from start position
until the end.
Function signature
\nsubstring(string: string, start position: number, length: number): string\n
\nThe start position
starts at the index 1
. The last position is -1
.
Examples
\nsubstring("foobar", 3, 3)\n// "oba"\n\nsubstring("foobar", -3, 2)\n// "ba"\n\nsubstring("foobar", 3, 10)\n// "obar"\n
\n"
},
{
"name": "string length(string)",
@@ -447,6 +455,22 @@
"name": "extract(string, pattern)",
"description": "Camunda Extension
\nReturns all matches of the pattern in the given string. Returns an empty list if the pattern doesn't\nmatch.
\nFunction signature
\nextract(string: string, pattern: string): list<string>\n
\nThe pattern
is a string that contains a regular expression.
Examples
\nextract("references are 1234, 1256, 1378", "12[0-9]*")\n// ["1234","1256"]\n
\n"
},
+ {
+ "name": "trim(string)",
+ "description": "Camunda Extension
\nReturns the given string without leading and trailing spaces.
\nFunction signature
\ntrim(string: string): string\n
\nExamples
\ntrim(" hello world ")\n// "hello world"\n\ntrim("hello world ")\n// "hello world"\n
\n"
+ },
+ {
+ "name": "uuid()",
+ "description": "Camunda Extension
\nReturns a UUID (Universally Unique Identifier) with 36 characters.
\nFunction signature
\nuuid(): string\n
\nExamples
\nuuid()\n// "7793aab1-d761-4d38-916b-b7270e309894"\n
\n"
+ },
+ {
+ "name": "to base64(value)",
+ "description": "Camunda Extension
\nReturns the given string encoded in Base64 format.
\nFunction signature
\nto base64(value: string): string\n
\nExamples
\nto base64("FEEL")\n// "RkVFTA=="\n
\n"
+ },
+ {
+ "name": "is blank(string)",
+ "description": "Camunda Extension
\nReturns true
if the given string is blank (empty or contains only whitespaces).
Function signature
\nis blank(string: string): boolean\n
\nExamples
\nis blank("")\n// true\n\nis blank(" ")\n// true\n\nis blank("hello world")\n// false\n
\n"
+ },
{
"name": "now()",
"description": "Returns the current date and time including the timezone.
\nFunction signature
\nnow(): date and time\n
\nExamples
\nnow()\n// date and time("2020-07-31T14:27:30@Europe/Berlin")\n
\n"
@@ -478,21 +502,5 @@
{
"name": "last day of month(date)",
"description": "Camunda Extension
\nTakes the month of the given date or date-time value and returns the last day of this month.
\nFunction signature
\nlast day of month(date: date): date\n
\nlast day of month(date: date and time): date\n
\nExamples
\nlast day of month(date("2022-10-01"))\n// date("2022-10-31"))\n\nlast day of month(date and time("2022-10-16T12:00:00"))\n// date("2022-10-31"))\n
\n"
- },
- {
- "name": "is empty(list)",
- "description": "Camunda Extension
\nReturns true if the given list is empty. Otherwise, returns false.
\nFunction signature
\nis empty(list: list): boolean
\nExamples
\nis empty([])\n// true\n\nis empty([1,2,3])\n// false\n
"
- },
- {
- "name": "trim(string)",
- "description": "Camunda Extension
\nReturns the given string without leading and trailing spaces.
\nFunction signature
\ntrim(string: string): string
\nExamples
\ntrim(\" hello world \")\n// \"hello world\"\n\ntrim(\"hello world \")\n// \"hello world\"\n
"
- },
- {
- "name": "uuid()",
- "description": "Camunda Extension
\nReturns a UUID (Universally Unique Identifier) with 36 characters.
\nFunction signature
\nuuid(): string
\nExamples
\nuuid()\n// \"7793aab1-d761-4d38-916b-b7270e309894\"\n
"
- },
- {
- "name": "to base64(string)",
- "description": "Camunda Extension
\nReturns the given string encoded in Base64 format.
\nFunction signature
\nto base64(value: string): string
\nExamples
\nto base64(\"FEEL\")\n// \"RkVFTA==\"\n
"
}
]
\ No newline at end of file