Documentation ¶
Index ¶
- type CanFrame
- type ReceiveCallback
- type WsMsg
- type WsServer
- func (t *WsServer) OnConnect(id int)
- func (t *WsServer) OnDisconnect(id int)
- func (t *WsServer) OnFailure(exited bool, err error)
- func (t *WsServer) OnReceive(msg websocket.Message)
- func (s *WsServer) Send(msg any) error
- func (s *WsServer) SendCanFrame(frame CanFrame) error
- func (s *WsServer) SendEncoded(msg WsMsg) error
- func (s *WsServer) Serve() error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CanFrame ¶
type ReceiveCallback ¶
type ReceiveCallback func(msg any)
type WsMsg ¶
type WsMsg struct { Device string `json:"device"` Msg cancoder.CanValueDef `json:"message"` }
type WsServer ¶
type WsServer struct {
// contains filtered or unexported fields
}
func NewWsServer ¶
func (*WsServer) OnDisconnect ¶
func (*WsServer) SendCanFrame ¶
func (*WsServer) SendEncoded ¶
Click to show internal directories.
Click to hide internal directories.