dcsex.check

Library for checking input values

Contents

  1. Functions
    1. _t.type(val, typestr, lvl)
    2. _t.bool(val, lvl)
    3. _t.number(num, lvl)
    4. _t.string(str, lvl)
    5. _t.table(t, lvl)
    6. _t.func(f, lvl)
    7. _t.range(val, min, max, lvl)
    8. _t.tblkey(val, tbl, tblstr, lvl)

Functions

_t.type(val, typestr, lvl)

Parameters

val
the value to check
typestr
the type string to compare with
lvl
the stack level to start at/blame for the error

_t.bool(val, lvl)

Parameters

val
the value to check
lvl
the stack level to start at/blame for the error

_t.number(num, lvl)

Parameters

num
the number to check
lvl
the stack level to start at/blame for the error

_t.string(str, lvl)

Parameters

str
the string to check
lvl
the stack level to start at/blame for the error

_t.table(t, lvl)

Parameters

t
the table to check
lvl
the stack level to start at/blame for the error

_t.func(f, lvl)

Parameters

f
the function reference to check
lvl
the stack level to start at/blame for the error

_t.range(val, min, max, lvl)

Parameters

val
the value to check
min
min value
max
max value
lvl
the stack level to start at/blame for the error

_t.tblkey(val, tbl, tblstr, lvl)

Parameters

val
the value to check
tbl
the table to check in
tblstr
name of table used in the error msg to help the user
lvl
the stack level to start at/blame for the error