Appearance
Vararg
Inherits: LibTSMModule
Functions
In
lua
function Lua.Vararg.In(value, ...)
-> booleanReturns whether not the value exists within the vararg.
Parameters:
| Name | Type | Description |
|---|---|---|
value | any | The value to search for |
... | any | Any number of values to search in |
Returns:
| Type | Description |
|---|---|
boolean |
IntoTable
lua
function Lua.Vararg.IntoTable(tbl, ...)Stores a varag into a table.
Parameters:
| Name | Type | Description |
|---|---|---|
tbl | table | The table to store the values in |
... | any | Zero or more values to store in the table |
Iterator
lua
function Lua.Vararg.Iterator(...)
-> fun():number, any, table, numberCreates an iterator from a vararg. NOTE: This iterator must be run to completion and not be interrupted (i.e. with a break or return).
Parameters:
| Name | Type | Description |
|---|---|---|
... | any | The values to iterate over |
Returns:
| Type | Description |
|---|---|
fun():number, any | Iterator with fields: index, value |
table | |
number |