SFCodeBlocks Reference
The sections that follow explain each SFCodeBlock instruction in detail, while the following table provides a summary of the instruction set grouped by category.
| Category | Name (Label) | Description |
|---|---|---|
| Programming | Function | Function declaration - represents the beginning of the function |
| Main | Main body of the analytic declaration | |
| Break | Interrupt the execution of a loop | |
| Call | Call a function | |
| Return | Exit from the current function | |
| End | Interrupt the execution of the analytic | |
| Comment | Comment | Define a comment |
| Logic | If Then | Canonical If then |
| If Then Else | Canonical If then else | |
| While | Canonical While | |
| For | Loop | |
| For Each | Loop on a collection | |
| Variable | Set | [Declare] set a global variable |
| Interface | [Declare] an interface global variable (parameters) | |
| Debug | Debug Print | Formattable debug print |
| Analytics | Report | Formattable report print |
| Exec Analytic | Exec another analytic | |
| Wait Analytic | Wait for analytic completion | |
| Action | Define possible action | |
| SF Connections | ForEachConnected | Loop for each connect element integrated with a Switch condition by the connection type (input, output, attached) |
| ForEachConnectedInput | Loop for each element connected in input | |
| ForEachConnectedOutput | Loop for each element connected in output | |
| ForEachConnectedAttached | Loop for each element attached | |
| SF Case | Select | Define the new working space. Select modifies the elements collection according to the selection criteria. |
| Case Checkin | Commit changes and release the case | |
| Case Checkout | Try to check out the selected case | |
| Case UndoCheckout | Case release | |
| Case Runner | Execute case actions such as: Collect Elements, Collect Inputs... | |
| Case Select | Switch the execution context over a specific case | |
| Task | Task Run | Queues the specified function to run on parallel and returns a task handle for that work. |
| Task await | Waits for the task to complete execution. |