Documentation
¶
Index ¶
Constants ¶
View Source
const ( ServiceDispatcher = "dispatcher" DefaultBufSize = 65535 )
View Source
const (
ServiceTimer = "timer"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DispatcherHander ¶
type DispatcherHander interface{}
type IServiceDispatcher ¶
type IServiceDispatcher interface {
CreateDispatcher(dispatcherName string, params ...uint) error
RemoveDispatcher(dispatcherName string) error
Dispatch(dispatcherName string, data interface{}) error
AddDispatcherHandler(dispatcherName string, handler DispatcherHander, handlerName ...string) error
RemoveDispatcherHandler(dispatcherName string, handlerName string) error
}
async producer/consumer
type IServiceTimer ¶
type IServiceTimer interface {
CreateTimer(timerName string, handler TimerHander, itv ...time.Duration) error
RemoveTimer(timerName string) error
}
loop task based on duration trigger
type TimerHander ¶
type TimerHander func()
Click to show internal directories.
Click to hide internal directories.