GenericNamedArraylist methods syntax: Difference between revisions
m (Automatically generated page update) |
m (Automatically generated page update) |
||
Line 2: | Line 2: | ||
replaced, so any manual edits will be lost. You've been warned. --> | replaced, so any manual edits will be lost. You've been warned. --> | ||
{{Template:Syntax list header|class=GenericNamedArraylist}} | {{Template:Syntax list header|class=GenericNamedArraylist}} | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top:1px solid;"><span class="term">anyNal</span><span class="literal">:[[Audit (GenericNamedArraylist subroutine)|Audit]]</span><span class="literal">(</span> <span class="term" title="ItemFunction">itemFunction</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Number">NumWidth=</span> <span class="term" title="Number">number</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Separator=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top:1px solid;"><span class="term">anyNal</span><span class="literal">:[[Audit (GenericNamedArraylist subroutine)|Audit]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="term" title="ItemFunction">itemFunction</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Number">NumWidth=</span> <span class="term" title="Number">number</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Separator=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> - | ||
<span class="squareb">[</span><span class="literal" title="Number">Start=</span> <span class="term" title="Number">number</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Number">MaxItems=</span> <span class="term" title="Number">number</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Label=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> - | |||
<span class="squareb">[</span><span class="literal" title="Number">NameWidth=</span> <span class="term" title="Number">number</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p> | |||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[Average (GenericNamedArraylist function)|Average]]</span><span class="literal">(</span> <span class="term" title="ItemFunction">itemFunction</span><span class="literal">)</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[Average (GenericNamedArraylist function)|Average]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="term" title="ItemFunction">itemFunction</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[Count (GenericNamedArraylist property)|Count]]</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[Count (GenericNamedArraylist property)|Count]]</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[CountSubset (GenericNamedArraylist function)|CountSubset]]</span><span class="literal">(</span> <span class="term" title="SelectionCriterion">selectionCriterion</span><span class="literal">)</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[CountSubset (GenericNamedArraylist function)|CountSubset]]</span><span class="literal">(</span> <span class="term" title="SelectionCriterion">selectionCriterion</span><span class="literal">)</span></p> | ||
Line 16: | Line 16: | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%currentItem</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[ItemByNumber (GenericNamedArraylist property)|ItemByNumber]]</span><span class="literal">(</span> <span class="term" title="Number">number</span><span class="literal">)</span> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%currentItem</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[ItemByNumber (GenericNamedArraylist property)|ItemByNumber]]</span><span class="literal">(</span> <span class="term" title="Number">number</span><span class="literal">)</span> | ||
<span class="term">anyNal</span><span class="literal">:[[ItemByNumber (GenericNamedArraylist property)|ItemByNumber]]</span><span class="literal">(</span> <span class="term" title="Number">number</span><span class="literal">)</span> <span class="literal">= </span><span class="term">newItem</span></p> | <span class="term">anyNal</span><span class="literal">:[[ItemByNumber (GenericNamedArraylist property)|ItemByNumber]]</span><span class="literal">(</span> <span class="term" title="Number">number</span><span class="literal">)</span> <span class="literal">= </span><span class="term">newItem</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%item</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[MaximumItem (GenericNamedArraylist function)|MaximumItem]]</span><span class="literal">(</span> <span class="term" title="ItemFunction">itemFunction</span><span class="literal">)</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%item</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[MaximumItem (GenericNamedArraylist function)|MaximumItem]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="term" title="ItemFunction">itemFunction</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%item</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[MinimumItem (GenericNamedArraylist function)|MinimumItem]]</span><span class="literal">(</span> <span class="term" title="ItemFunction">itemFunction</span><span class="literal">)</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%item</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[MinimumItem (GenericNamedArraylist function)|MinimumItem]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="term" title="ItemFunction">itemFunction</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%anyNal</span><span class="literal"> =</span> <span class="squareb">[</span><span class="literal">%(GenericNamedArraylist Of </span><span class="term">itemType</span><span class="literal">):</span><span class="squareb">]</span><span class="literal">[[New (GenericNamedArraylist constructor)|New]]</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%anyNal</span><span class="literal"> =</span> <span class="squareb">[</span><span class="literal">%(GenericNamedArraylist Of </span><span class="term">itemType</span><span class="literal">):</span><span class="squareb">]</span><span class="literal">[[New (GenericNamedArraylist constructor)|New]]</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">anyNal</span><span class="literal">:[[Print (GenericNamedArraylist subroutine)|Print]]</span><span class=" | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">anyNal</span><span class="literal">:[[Print (GenericNamedArraylist subroutine)|Print]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="term" title="ItemFunction">itemFunction</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Number">NumWidth=</span> <span class="term" title="Number">number</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Separator=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> - | ||
<span class="squareb">[</span><span class="literal" title="Number">Start=</span> <span class="term" title="Number">number</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Number">MaxItems=</span> <span class="term" title="Number">number</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Label=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> - | |||
<span class="squareb">[</span><span class="literal" title="Number">NameWidth=</span> <span class="term" title="Number">number</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p> | |||
< | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%al</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[SortNew (GenericNamedArraylist function)|SortNew]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="term" title="SortOrder">sortOrder</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p> | ||
< | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[StandardDeviation (GenericNamedArraylist function)|StandardDeviation]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="term" title="ItemFunction">itemFunction</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[Sum (GenericNamedArraylist function)|Sum]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="term" title="ItemFunction">itemFunction</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p> | |||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">anyNal</span><span class="literal">:[[Trace (GenericNamedArraylist subroutine)|Trace]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="term" title="ItemFunction">itemFunction</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Number">NumWidth=</span> <span class="term" title="Number">number</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Separator=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> - | |||
<span class="squareb">[</span><span class="literal" title="Number">Start=</span> <span class="term" title="Number">number</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="Number">MaxItems=</span> <span class="term" title="Number">number</span><span class="squareb">]</span><span class="comma">,</span> <span class="squareb">[</span><span class="literal" title="String">Label=</span> <span class="term" title="String">string</span><span class="squareb">]</span><span class="comma">,</span> - | |||
<span class="squareb">[</span><span class="literal" title="Number">NameWidth=</span> <span class="term" title="Number">number</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p> | |||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%currentBoolean</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[UseDefault (GenericNamedArraylist property)|UseDefault]]</span> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%currentBoolean</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[UseDefault (GenericNamedArraylist property)|UseDefault]]</span> | ||
<span class="term">anyNal</span><span class="literal">:[[UseDefault (GenericNamedArraylist property)|UseDefault]]</span> <span class="literal">= </span><span class="term">newBoolean</span></p> | <span class="term">anyNal</span><span class="literal">:[[UseDefault (GenericNamedArraylist property)|UseDefault]]</span> <span class="literal">= </span><span class="term">newBoolean</span></p> | ||
<p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[Variance (GenericNamedArraylist function)|Variance]]</span><span class="literal">(</span> <span class="term" title="ItemFunction">itemFunction</span><span class="literal">)</span></p> | <p class="syntax" style="margin-bottom:0px; border-bottom:1px solid; border-left:1px solid; border-right:1px solid; border-top: none; margin-top:0px;"><span class="term">%number</span><span class="literal"> =</span> <span class="term">anyNal</span><span class="literal">:[[Variance (GenericNamedArraylist function)|Variance]]</span><span class="squareb">[</span><span class="literal">(</span> <span class="squareb">[</span><span class="term" title="ItemFunction">itemFunction</span><span class="squareb">]</span><span class="literal">)</span><span class="squareb">]</span></p> |
Revision as of 19:35, 18 July 2012
The syntax for each of the GenericNamedArraylist class methods is shown below.
Square brackets indicate optional elements of the method invocation. See also the notation conventions for methods and the List of GenericNamedArraylist methods.
anyNal:Audit[( [itemFunction], [NumWidth= number], [Separator= string], - [Start= number], [MaxItems= number], [Label= string], - [NameWidth= number])]
%number = anyNal:Average[( [itemFunction])]
%number = anyNal:Count
%number = anyNal:CountSubset( selectionCriterion)
%currentItem = anyNal:Default anyNal:Default = newItem
%item = anyNal:FindNextItem( selectionCriterion, [Start= number])
%number = anyNal:FindNextItemNumber( selectionCriterion, [Start= number])
%item = anyNal:FindPreviousItem( selectionCriterion, [Start= number])
%number = anyNal:FindPreviousItemNumber( selectionCriterion, [Start= number])
%currentItem = anyNal:ItemByNumber( number) anyNal:ItemByNumber( number) = newItem
%item = anyNal:MaximumItem[( [itemFunction])]
%item = anyNal:MinimumItem[( [itemFunction])]
%anyNal = [%(GenericNamedArraylist Of itemType):]New
anyNal:Print[( [itemFunction], [NumWidth= number], [Separator= string], - [Start= number], [MaxItems= number], [Label= string], - [NameWidth= number])]
%al = anyNal:SortNew[( [sortOrder])]
%number = anyNal:StandardDeviation[( [itemFunction])]
%number = anyNal:Sum[( [itemFunction])]
anyNal:Trace[( [itemFunction], [NumWidth= number], [Separator= string], - [Start= number], [MaxItems= number], [Label= string], - [NameWidth= number])]
%currentBoolean = anyNal:UseDefault anyNal:UseDefault = newBoolean
%number = anyNal:Variance[( [itemFunction])]