Documentation
¶
Index ¶
- func InitManager() error
- type JSFunc
- type Manager
- func (m *Manager) ConvName(n string) (string, bool)
- func (m *Manager) Create(script *Script) error
- func (m *Manager) Delete(id string) error
- func (m *Manager) Export() map[string]string
- func (m *Manager) Function(name string) (api.Function, error)
- func (m *Manager) FunctionPluginInfo(funcName string) (plugin.EXTENSION_TYPE, string, string)
- func (m *Manager) GetScript(id string) (*Script, error)
- func (m *Manager) HasFunctionSet(_ string) bool
- func (m *Manager) Import(ctx context.Context, scripts map[string]string) map[string]string
- func (m *Manager) List() ([]string, error)
- func (m *Manager) PartialImport(ctx context.Context, scripts map[string]string) map[string]string
- func (m *Manager) Reset()
- func (m *Manager) Status() map[string]string
- func (m *Manager) Update(script *Script) error
- func (m *Manager) UpsertByJson(k string, v string) error
- type Script
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitManager ¶
func InitManager() error
InitManager initialize the manager, only called once by the server
Types ¶
type JSFunc ¶
type JSFunc struct {
// contains filtered or unexported fields
}
JSFunc is stateful Each instance has its own vm
func (*JSFunc) Exec ¶
func (f *JSFunc) Exec(ctx api.FunctionContext, args []any) (interface{}, bool)
func (*JSFunc) IsAggregate ¶
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
func GetManager ¶
func GetManager() *Manager
func (*Manager) FunctionPluginInfo ¶
func (*Manager) HasFunctionSet ¶
func (*Manager) Import ¶
Import the JavaScript functions from the map. This is usually called after reset to override all settings
func (*Manager) PartialImport ¶
Click to show internal directories.
Click to hide internal directories.