CountSubset (GenericNamedArraylist function)

From m204wiki
Revision as of 20:13, 17 July 2012 by JAL2 (talk | contribs)
Jump to navigation Jump to search

Number of items that match some selection criteria (FloatNamedArraylist, NamedArraylist, and UnicodeNamedArraylist classes)

[Introduced in Sirius Mods 7.8]


The CountSubset function returns the number of items in a collection that match a specified selection criterion. It is related to the SubsetNew collection method, which returns not the count but a collection of the matching items for a specified criterion.

Syntax

%number = anyNal:CountSubset( selectionCriterion)

Syntax terms

%number A numeric variable to contain the count of matching items.
anyNal A NamedArraylist, FloatNamedArraylist, or UnicodeNamedArraylist object variable.
selectionCriterion A SelectionCriterion object, which is a relational expression that is applied to each collection item value to determine whether the value satisfies the expression. This is a required parameter.

Usage notes

Examples

See also