MCPcopy Create free account
hub / github.com/astercloud/aster / RegisterRoom

Method RegisterRoom

pkg/asteros/asteros.go:154–164  ·  view source on GitHub ↗

RegisterRoom 注册 Room

(id string, r *core.Room)

Source from the content-addressed store, hash-verified

152
153// RegisterRoom 注册 Room
154func (os *AsterOS) RegisterRoom(id string, r *core.Room) error {
155 // 注册到 Registry
156 if err := os.registry.RegisterRoom(id, r); err != nil {
157 return err
158 }
159
160 // 通知所有 Interfaces
161 os.notifyRoomRegistered(r)
162
163 return nil
164}
165
166// RegisterWorkflow 注册 Workflow
167func (os *AsterOS) RegisterWorkflow(id string, wf workflow.Agent) error {

Callers 3

TestRegisterRoomFunction · 0.45
mainFunction · 0.45
mainFunction · 0.45

Calls 1

notifyRoomRegisteredMethod · 0.95

Tested by 1

TestRegisterRoomFunction · 0.36