Documentation ¶
Index ¶
Constants ¶
View Source
const (
//GlobalKey global properties key,call them through the global.xx method
GlobalKey = "global"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GojaJsEngine ¶
type GojaJsEngine struct {
// contains filtered or unexported fields
}
GojaJsEngine goja js engine
func NewGojaJsEngine ¶
func NewGojaJsEngine(config types.Config, jsScript string, fromVars map[string]interface{}) (*GojaJsEngine, error)
NewGojaJsEngine Create a new instance of the JavaScript engine
func (*GojaJsEngine) Execute ¶
func (g *GojaJsEngine) Execute(functionName string, argumentList ...interface{}) (out interface{}, err error)
Execute Execute JavaScript script
func (*GojaJsEngine) PreCompileJs ¶ added in v0.20.0
func (g *GojaJsEngine) PreCompileJs(config types.Config) error
PreCompileJs Precompiled UDF JavaScript file
func (*GojaJsEngine) Stop ¶
func (g *GojaJsEngine) Stop()
Click to show internal directories.
Click to hide internal directories.