Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var DefaultSendingCap = int64(1024)
View Source
var DefaultTimeoutMls = int64(1000) // one second
View Source
var ErrIdFieldNotFound = errors.New("request id not found")
View Source
var ErrNoMessageType = errors.New("message type not found")
View Source
var ErrNoResponse = errors.New("no response")
View Source
var ErrRequestNotFound = errors.New("request not found")
View Source
var ErrTimeoutError = errors.New("timeout error")
View Source
var ErrUnsupportedMessageType = errors.New("message type not supported")
Functions ¶
func NewRequestCtx ¶
func NewSyncConn ¶
func NewSyncConn() *syncConn
Types ¶
type Client ¶
type Client interface { ClientId() int64 Connect() error Reconnect() error IsActive() bool Stats() map[string]int64 SetMonitor(PerformanceMonitor) SetConnectionHandler(ConnectionHandler) SetErrorHandler(ErrorHandler) SetTimeout(timeoutMls int64) CancelRequest(requestId int64) CallFunction(name string, args value.Value) (value.Value, error) GetStream(name string, args value.Value, receiveCap int) (<-chan value.Value, int64, error) PutStream(name string, args value.Value, putCh <-chan value.Value) error Chat(name string, args value.Value, receiveCap int, putCh <-chan value.Value) (<-chan value.Value, int64, error) Close() error }
type ConnectionHandler ¶
type ErrorHandler ¶
type PerformanceMonitor ¶
must be fast function
Source Files
¶
Click to show internal directories.
Click to hide internal directories.