27 lines
586 B
Go
27 lines
586 B
Go
package functions
|
|
|
|
import (
|
|
"maps"
|
|
|
|
"Moonshark/functions/http"
|
|
|
|
luajit "git.sharkk.net/Sky/LuaJIT-to-Go"
|
|
)
|
|
|
|
// Registry holds all available Go functions for Lua modules
|
|
type Registry map[string]luajit.GoFunction
|
|
|
|
// GetAll returns all registered functions
|
|
func GetAll() Registry {
|
|
registry := make(Registry)
|
|
|
|
maps.Copy(registry, GetJSONFunctions())
|
|
maps.Copy(registry, GetStringFunctions())
|
|
maps.Copy(registry, GetMathFunctions())
|
|
maps.Copy(registry, GetFSFunctions())
|
|
maps.Copy(registry, GetCryptoFunctions())
|
|
maps.Copy(registry, http.GetHTTPFunctions())
|
|
|
|
return registry
|
|
}
|