MCPcopy Create free account
hub / github.com/djherbis/socket / Socket

Interface Socket

socket.go:16–33  ·  view source on GitHub ↗

Socket is a Server-side socket

Source from the content-addressed store, hash-verified

14
15// Socket is a Server-side socket
16type Socket interface {
17 ClientSocket
18
19 // Join adds a Socket to the passed Room
20 Join(room string)
21
22 // Leave removes a Socket from the passed Room
23 Leave(room string)
24
25 // Rooms returns the rooms this Socket is in
26 Rooms() []string
27
28 // To returns an Emitter to the passed room.
29 To(string) Emitter
30
31 // Request returns the request which this Socket was created from.
32 Request() *http.Request
33}
34
35type socket struct {
36 mu sync.RWMutex

Callers 7

JoinMethod · 0.65
LeaveMethod · 0.65
disconnectMethod · 0.65
ToMethod · 0.65
mainFunction · 0.65
mainFunction · 0.65
RequestMethod · 0.65

Implementers 1

socketsocket.go

Calls

no outgoing calls

Tested by

no test coverage detected