MCPcopy Create free account
hub / github.com/GoEdgeLab/EdgeNode / On

Method On

internal/apps/app_cmd.go:121–126  ·  view source on GitHub ↗

On 添加指令

(arg string, callback func())

Source from the content-addressed store, hash-verified

119
120// On 添加指令
121func (this *AppCmd) On(arg string, callback func()) {
122 this.directives = append(this.directives, &Directive{
123 Arg: arg,
124 Callback: callback,
125 })
126}
127
128// Run 运行
129func (this *AppCmd) Run(main func()) {

Callers 1

mainFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected