Documentation ¶
Index ¶
- type Context
- type DefaultMessageService
- func (m *DefaultMessageService) Broadcast(msgType string, payload interface{}) error
- func (m *DefaultMessageService) Identifier() string
- func (m *DefaultMessageService) Request(to, msgType string, payload interface{}, timeout time.Duration) (interface{}, error)
- func (m *DefaultMessageService) Send(to, msgType string, payload interface{}) error
- func (m *DefaultMessageService) SendToAny(msgType string, payload interface{}) error
- type HandlerFunc
- type Message
- type MqService
- type MsgType
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Context ¶
type Context struct {
// contains filtered or unexported fields
}
func (*Context) GetMessage ¶
type DefaultMessageService ¶ added in v0.1.0
type DefaultMessageService struct {
MqService *MqService
}
func (*DefaultMessageService) Broadcast ¶ added in v0.1.0
func (m *DefaultMessageService) Broadcast(msgType string, payload interface{}) error
func (*DefaultMessageService) Identifier ¶ added in v0.1.0
func (m *DefaultMessageService) Identifier() string
func (*DefaultMessageService) Request ¶ added in v0.1.0
func (m *DefaultMessageService) Request(to, msgType string, payload interface{}, timeout time.Duration) (interface{}, error)
func (*DefaultMessageService) Send ¶ added in v0.1.0
func (m *DefaultMessageService) Send(to, msgType string, payload interface{}) error
func (*DefaultMessageService) SendToAny ¶ added in v0.1.0
func (m *DefaultMessageService) SendToAny(msgType string, payload interface{}) error
type HandlerFunc ¶
type HandlerFunc func(ctx *Context) interface{}
type MqService ¶
type MqService struct {
// contains filtered or unexported fields
}
func NewMqService ¶
func (*MqService) AddHandler ¶
func (mq *MqService) AddHandler(msgType MsgType, handler HandlerFunc) error
Click to show internal directories.
Click to hide internal directories.