Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ConnectionHandler ¶
type ConnectionHandler func(Socket)
type Server ¶
type Server struct {
Config Config
Events map[string]ConnectionHandler
RandFunc func() int
// contains filtered or unexported fields
}
the server struct
func (*Server) On ¶
func (s *Server) On(eventName string, cb ConnectionHandler)
func (*Server) StopListening ¶
func (s *Server) StopListening()
func (*Server) UserDisconnect ¶
this function should be called after disconnecting a user
Click to show internal directories.
Click to hide internal directories.