builtin

package
v1.2.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 10, 2022 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FuncsInit

func FuncsInit(out io.Writer)

func GetConstant added in v1.1.0

func GetConstant(name string) (val interface{}, found bool)

func HasConstant added in v1.1.0

func HasConstant(name string) bool

func HasFunction added in v1.1.0

func HasFunction(name string) bool

func ListConstants added in v1.1.0

func ListConstants() map[string]interface{}

func ListFunctions added in v1.1.0

func ListFunctions() map[string]Func

func RegisterConstant added in v1.2.2

func RegisterConstant[T string | bool | uint64 | int64 | float64](name string, value T)

func RegisterFunction added in v1.2.2

func RegisterFunction(name string, function Func)

Types

type Func

type Func struct {
	Args string
	Desc string
	Exec func(args ...interface{}) (interface{}, error)
}

func GetFunction added in v1.1.0

func GetFunction(name string) (function Func, found bool)

type FuncMap

type FuncMap map[string]Func

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL