Default (GenericNamedArraylist property): Difference between revisions

From m204wiki
Jump to navigation Jump to search
m (1 revision)
m (match syntax table to diagram, couple of tags, lots of edits)
Line 1: Line 1:
{{Template:GenericNamedArraylist:Default subtitle}}
{{Template:GenericNamedArraylist:Default subtitle}}


This ReadWrite property indicates the value to be returned if a
The <var>Default</var> ReadWrite property indicates the value to be returned if a requested item name is not in the method <var>FloatNamedArraylist</var> / <var>NamedArraylist</var> / <var>UnicodeNamedArraylist</var> and the <var>[[UseDefault (NamedArraylist property)|UseDefault]]</var> property is set to <code>True</code>.
requested item name is not in the NamedArraylist and
 
the [[UseDefault (NamedArraylist property)|UseDefault]] property is set
to <tt>True</tt>.
==Syntax==
==Syntax==
{{Template:GenericNamedArraylist:Default syntax}}
{{Template:GenericNamedArraylist:Default syntax}}
===Syntax terms===
===Syntax terms===
<table class="syntaxTable">
<table class="syntaxTable">
<tr><th>%val</th>
<tr><th>%currentItem</th>
<td>A value that matches the NamedArraylist item type or one that can be converted to that type. </td></tr>
<td>A value that matches the array list item type, or one that can be converted to that type; that will receive the current default. </td></tr>
<tr><th>%namrayl</th>
<tr><th>anyNal</th>
<td>A NamedArraylist object.</td></tr>
<td>A array list object.</td></tr>
<tr><th>newItem</th>
<td>A new value that matches the array list item type, or one that can be converted to that type; that will become the new default.</td></tr>
</table>
</table>
==Usage notes==
==Usage notes==
<ul>
<ul><li>The initial value of the Default property varies with the array list item type:
<li>The initial value of the Default property varies with the
NamedArraylist item type:
<table>
<table>
<tr><th>Value</th><th>Item type</th></tr>
<tr><th>Item type</th><th>Value</th></tr>
<tr><td>0</td><td>>Float and Fixed</td></tr>
<tr><td>Float and Fixed</td><td>0</td></tr>
<tr><td>null string</td><td>>String, Longstring, and Unicode</td></tr>
<tr><td>String, <var>Longstring</var>, and Unicode</td><td>null string</td></tr>
<tr><td>null reference</td><td>>object</td></tr>
<tr><td>object</td><td>null reference</td></tr>
</table>
</table></ul>
</ul>
 
==See also==
==See also==
{{Template:GenericNamedArraylist:Default footer}}
{{Template:GenericNamedArraylist:Default footer}}

Revision as of 08:06, 2 March 2011

Value for Item to return when Name has no value (FloatNamedArraylist, NamedArraylist, and UnicodeNamedArraylist classes)


The Default ReadWrite property indicates the value to be returned if a requested item name is not in the method FloatNamedArraylist / NamedArraylist / UnicodeNamedArraylist and the UseDefault property is set to True.

Syntax

%currentItem = anyNal:Default anyNal:Default = newItem

Syntax terms

%currentItem A value that matches the array list item type, or one that can be converted to that type; that will receive the current default.
anyNal A array list object.
newItem A new value that matches the array list item type, or one that can be converted to that type; that will become the new default.

Usage notes

  • The initial value of the Default property varies with the array list item type:
    Item typeValue
    Float and Fixed0
    String, Longstring, and Unicodenull string
    objectnull reference

See also