skip to main content
Corticon Studio: Rule Language Guide : Rule operator details and examples : Iterate
 

Try Corticon Now

Iterate

SYNTAX

<Collection> ->iterate(<Expression>)

DESCRIPTION

Executes <Expression> for every element in <Collection>. <Collection> must be expressed as a unique alias.

USAGE RESTRICTIONS

The Operators row of the table in Summary Table of Vocabulary Usage Restriction does not apply. Special exceptions: ->iterate may only be used in Action Rows (section 5 in Sections of Rulesheet that correlate with usage restrictions).

RULESHEET EXAMPLE

This sample Rulesheet uses ->iterate to assign the value of test to string1 in every element in collection1 . See ->exists for more information on this operator.

SAMPLE RULETEST

A sample Ruletest provides three elements in collection1. Input and Output panels are shown below.