Files
mayfly-go/server/internal/msg/application/application.go

22 lines
390 B
Go
Raw Normal View History

2023-07-03 21:42:04 +08:00
package application
import (
2025-04-15 21:42:31 +08:00
_ "mayfly-go/internal/msg/msgx/sender" // 注册消息发送器
2024-01-21 22:52:20 +08:00
"mayfly-go/pkg/ioc"
2023-07-03 21:42:04 +08:00
)
func InitIoc() {
2026-02-01 13:35:23 +08:00
ioc.Register(new(msgAppImpl))
ioc.Register(new(msgChannelAppImpl))
ioc.Register(new(msgTmplAppImpl))
ioc.Register(new(msgTmplBizAppImpl))
2024-01-21 22:52:20 +08:00
}
2023-07-03 21:42:04 +08:00
func GetMsgApp() Msg {
2026-01-05 20:07:17 +08:00
return ioc.Get[Msg]()
2023-07-03 21:42:04 +08:00
}
func GetMsgTmplApp() MsgTmpl {
2026-01-05 20:07:17 +08:00
return ioc.Get[MsgTmpl]()
}