for
The following is a list of properties for the function for
:
Property | Value |
---|---|
brief | Evaluate a list of values (statements) while a condition is true with a list of initial and increment values |
category | script |
description | This creates a new structured block with a new nested variable scope. This function loops while condition is true. If the condition is false for the first iteration, the loop returns a null value. |
functionId | for |
functionLabel | for |
pure | true |
parameters | [ { "dataType": "list", "description": "This is a list of values (statements) to evaluate before the loop starts. The values will normally be a call to the \"assign\" function.", "name": "initial", "optional": true }, { "dataType": "boolean", "description": "While this condition is true, the loop will continue.", "name": "condition", "optional": true }, { "dataType": "list", "description": "This is a list of values (statements) to evaluate after each iteration of the loop. The values will normally be a call to the \"assign\" function.", "name": "increment", "optional": true }, { "dataType": "list", "description": "This is a list of values (statements) that are evaluated for each iteration of the loop. Each value in body is evaluated in order until the end of the list or until a \"break\", \"continue\", \"return\" or \"throw\" function is encountered.", "name": "body", "optional": true } ] |
returns | { "description": "The last value evaluated in body or null if condition evaluates to false the first time." } |
scriptSupport | true |