Documentation
¶
Index ¶
Constants ¶
const ( TypeNil = Type(iota) TypeBool TypeNumber TypeString TypeBools TypeNumbers TypeStrings TypeTable TypeArray TypeValue )
Various supported types
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Array ¶ added in v1.3.0
type Array []Value
Array represents the array of values
type Bool ¶
type Bool bool
Bool represents the boolean value
type Bools ¶ added in v0.0.4
type Bools []bool
Bools represents the boolean array value
type Module ¶
type Module interface {
// contains filtered or unexported methods
}
Module represents a loadable module.
type NativeModule ¶ added in v0.0.3
type NativeModule struct { Name string // The name of the module Version string // The module version string // contains filtered or unexported fields }
NativeModule represents a loadable native module.
func (*NativeModule) Register ¶ added in v0.0.3
func (m *NativeModule) Register(name string, function any) error
Register registers a function into the module.
func (*NativeModule) Unregister ¶ added in v0.0.3
func (m *NativeModule) Unregister(name string)
Unregister unregisters a function from the module.
type Nil ¶
type Nil struct{}
Nil represents the nil value
type Number ¶
type Number float64
Number represents the numerical value
type Numbers ¶ added in v0.0.4
type Numbers []float64
Numbers represents the number array value
type Script ¶
type Script struct {
// contains filtered or unexported fields
}
Script represents a LUA script
func FromReader ¶
FromReader reads a script fron an io.Reader
func FromString ¶
FromString reads a script fron a string
func (*Script) Concurrency ¶ added in v1.5.2
Concurrency returns the concurrency setting of the script
type ScriptModule ¶ added in v0.0.3
type ScriptModule struct { Script *Script // The script that contains the module Name string // The name of the module Version string // The module version string }
ScriptModule represents a loadable module written in LUA itself.
type String ¶
type String string
String represents the string value
type Strings ¶ added in v0.0.4
type Strings []string
Strings represents the string array value
type Table ¶ added in v0.0.7
Table represents a map of string to value
func (*Table) UnmarshalJSON ¶ added in v1.2.0
UnmarshalJSON unmarshals the type from JSON