Conn represents a WebSocket connection. Multiple goroutines may invoke methods on a Conn simultaneously.
| 161 | // |
| 162 | // Multiple goroutines may invoke methods on a Conn simultaneously. |
| 163 | type Conn struct { |
| 164 | config *Config |
| 165 | request *http.Request |
| 166 | |
| 167 | buf *bufio.ReadWriter |
| 168 | rwc io.ReadWriteCloser |
| 169 | |
| 170 | rio sync.Mutex |
| 171 | frameReaderFactory |
| 172 | frameReader |
| 173 | |
| 174 | wio sync.Mutex |
| 175 | frameWriterFactory |
| 176 | |
| 177 | frameHandler |
| 178 | PayloadType byte |
| 179 | defaultCloseStatus int |
| 180 | |
| 181 | // MaxPayloadBytes limits the size of frame payload received over Conn |
| 182 | // by Codec's Receive method. If zero, DefaultMaxPayloadBytes is used. |
| 183 | MaxPayloadBytes int |
| 184 | } |
| 185 | |
| 186 | // Read implements the io.Reader interface: |
| 187 | // it reads data of a frame from the WebSocket connection. |
nothing calls this directly
no outgoing calls
no test coverage detected