This is an old revision of the document!
The purpose of the CaseOf is to allow the value of a variable or expression to control the flow of program execution via a multiway branch. The main reasons for using a CaseOf include improving clarity, by reducing otherwise repetitive coding
Name | Mandatory | Description |
---|---|---|
expression | Yes | An arbitrary expression (string or number) |
statement_<a> | no | The content (html text or template filename) to return if the expression evaluate to <a> |
… | … | … |
statement_<n> | no | The content (html text or template filename) to return if the expression evaluate to <n> |
Default | no | Default value to return if no result found (else raise an error) |
<#caseof expression="<#url_PageNumber>" statement_0="their is no page" statement_1="their is at least 1 page" default="their is at least <#url_PageNumber> pages">