List
19 commands. Toolkit id ooa.list.
| Command | What it does |
|---|---|
| Add item | Add an item at the end, or at a position. |
| Append list | Join two lists into one, the second after the first. |
| Clear | Return an empty list; map it back to the variable to empty it. |
| Filter | Keep the items that pass a test, such as greater than 100 or contains Acme; for a list of records, test one field. |
| Find item | Return the zero-based position of the first (or last) item equal to a value. |
| Get item | Read the item at a position. |
| Get size | Number of items. |
| Items in both lists | Return the items of the first list that are also in the second, in the first list's order, each once. |
| Items not in other list | Return the items of the first list that are not in the second, e.g. invoices not yet processed. |
| Join | Join items into one text with a separator. |
| List contains item | True when the list contains the value. |
| List is empty | True when the list has no items. |
| Remove duplicates | Keep the first occurrence of each value. |
| Remove item | Remove the item at a position, or every item equal to a value. |
| Reverse | Return the items in reverse order. |
| Select field | Turn a list of records (dictionaries) into a list of one field's values, e.g. the e-mail of every customer. |
| Set item | Replace the item at a position. |
| Shuffle | Return the items in a random order, e.g. to pick a random sample. |
| Sort | Sort items (numbers numerically, text alphabetically). |