Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GrpcWrapper ¶
type GrpcWrapper struct { ConnKey string // unique key *grpc.ClientConn context.Context // contains filtered or unexported fields }
func WrapGrpc ¶
func WrapGrpc(ctx context.Context, cc *grpc.ClientConn, connKey string) *GrpcWrapper
func (*GrpcWrapper) Close ¶
func (w *GrpcWrapper) Close() error
func (*GrpcWrapper) Err ¶
func (w *GrpcWrapper) Err() error
func (*GrpcWrapper) Key ¶
func (w *GrpcWrapper) Key() string
type WebsocketWrapper ¶
type WebsocketWrapper struct { context.Context *websocket.Conn UID string // contains filtered or unexported fields }
func (*WebsocketWrapper) AddCloseAction ¶
func (w *WebsocketWrapper) AddCloseAction(f func() error)
func (*WebsocketWrapper) AddPingAction ¶
func (w *WebsocketWrapper) AddPingAction(f func() error)
func (*WebsocketWrapper) Close ¶
func (w *WebsocketWrapper) Close() error
func (*WebsocketWrapper) Daemon ¶
func (w *WebsocketWrapper) Daemon()
Daemon is keep read msg from connection, and handle registered ping, pong, close events
func (*WebsocketWrapper) Err ¶
func (w *WebsocketWrapper) Err() error
func (*WebsocketWrapper) Key ¶
func (w *WebsocketWrapper) Key() string
Click to show internal directories.
Click to hide internal directories.