Version 4.11 (c) Jiri Babor September 2002
Note: Types of variables are indicated by bold prefixes.
syntax: | tmodified = app(table, okey, ovalue) |
comment: | append new entry, return modified table |
see also: | set, store |
syntax: | tmodified = App(table, skeysequence, ovalue) |
comment: | 'deep', recursive app for nested tables
append value in table under new (last) key in keys sequence return modified table |
see also: | app |
syntax: | s = dups(table) |
comment: | returns sequence of all duplicate entries in table |
comment: | constant, empty table, ET = {{}} |
example: | sequence mytable |
syntax: | ovalue = fetch(table, okey) |
comment: | return value of table element with specified key |
syntax: | ovalue = Fetch(table, skeysequence) |
comment: | 'deep' fetch : return value of element from nested table
the key sequence contains one key for every level, the last one associated directly with the returned value |
see also: | fetch |
syntax: | i = index(table, okey) |
comment: | return key index, or zero if key is not found
frequently used to verify existence of an entry |
syntax: | table = join(table1, table2) |
comment: | combine table1 with table2
table2 is effectively attached to end of table1 return combined table |
syntax: | tmodified = remove(table, okey) |
comment: | remove entry with the specified key, return modified table |
syntax: | tmodifiedtable = set(table, okey, onewvalue) |
comment: | replace specified table item with a new value
return modified table |
see also: | app, store |
syntax: | tmodifiedtable = Set(table, skeysequence, onewvalue) |
comment: | 'deep', recursive set for nested tables
replace specified table item with a new value the key sequence contains one key for every level, the value of the last one is replaced return modified table |
see also: | set |
syntax: | tmodifiedtable = store(table, okey, ovalue) |
comment: | store value in table under given key
if matching key is found, corresponding value is replaced otherwise new key as well as value are appended return modified table |
see also: | app, set |
syntax: | tmodifiedtable = tsort(table) |
comment: | shell sort table by keys in ascending order |