Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ServeFeedWs ¶
ServeFeedWs handles websocket requests from the peer.
Types ¶
type FeedClient ¶
type FeedClient struct {
// contains filtered or unexported fields
}
FeedClient Client is a middleman between the websocket connection and the hub.
type FeedHub ¶
type FeedHub struct { // Registered clients. Clients map[*FeedClient]bool // Inbound messages from the clients. Broadcast chan ReloadFeed Quit chan bool // contains filtered or unexported fields }
FeedHub Hub maintains the set of active clients and broadcasts messages to the clients.
func NewFeedHub ¶
func NewFeedHub() *FeedHub
type ReloadFeed ¶
type ReloadFeed struct { }
Click to show internal directories.
Click to hide internal directories.