2017-05-11 13:04:43 +00:00
|
|
|
// +build no_ws
|
|
|
|
|
|
|
|
package main
|
|
|
|
|
2017-06-10 07:58:15 +00:00
|
|
|
import "errors"
|
2017-05-11 13:04:43 +00:00
|
|
|
import "net/http"
|
|
|
|
|
2017-09-03 04:50:31 +00:00
|
|
|
var wsHub WS_Hub
|
2017-09-10 16:57:22 +00:00
|
|
|
var errWsNouser = errors.New("This user isn't connected via WebSockets")
|
2017-05-11 13:04:43 +00:00
|
|
|
|
2017-09-03 04:50:31 +00:00
|
|
|
type WS_Hub struct {
|
2017-05-11 13:04:43 +00:00
|
|
|
}
|
|
|
|
|
2017-09-10 16:57:22 +00:00
|
|
|
func (_ *WS_Hub) guestCount() int {
|
2017-05-11 13:04:43 +00:00
|
|
|
return 0
|
|
|
|
}
|
|
|
|
|
2017-09-10 16:57:22 +00:00
|
|
|
func (_ *WS_Hub) userCount() int {
|
2017-05-11 13:04:43 +00:00
|
|
|
return 0
|
|
|
|
}
|
|
|
|
|
2017-09-10 16:57:22 +00:00
|
|
|
func (hub *WS_Hub) broadcastMessage(_ string) error {
|
2017-06-10 07:58:15 +00:00
|
|
|
return nil
|
|
|
|
}
|
|
|
|
|
2017-09-10 16:57:22 +00:00
|
|
|
func (hub *WS_Hub) pushMessage(_ int, _ string) error {
|
|
|
|
return errWsNouser
|
2017-06-10 07:58:15 +00:00
|
|
|
}
|
|
|
|
|
2017-09-10 16:57:22 +00:00
|
|
|
func (hub *WS_Hub) pushAlert(_ int, _ int, _ string, _ string, _ int, _ int, _ int) error {
|
|
|
|
return errWsNouser
|
2017-06-10 07:58:15 +00:00
|
|
|
}
|
|
|
|
|
2017-09-10 16:57:22 +00:00
|
|
|
func (hub *WS_Hub) pushAlerts(_ []int, _ int, _ string, _ string, _ int, _ int, _ int) error {
|
|
|
|
return errWsNouser
|
2017-06-12 09:03:14 +00:00
|
|
|
}
|
|
|
|
|
2017-09-11 10:24:03 +00:00
|
|
|
func routeWebsockets(_ http.ResponseWriter, _ *http.Request, _ User) {
|
2017-05-11 13:04:43 +00:00
|
|
|
}
|