MCPcopy
hub / github.com/nats-io/nats.go / wsNewReader

Function wsNewReader

ws.go:184–186  ·  view source on GitHub ↗
(r io.Reader)

Source from the content-addressed store, hash-verified

182}
183
184func wsNewReader(r io.Reader) *websocketReader {
185 return &websocketReader{r: r, ff: true}
186}
187
188// maxFrameSize returns the maximum allowed WebSocket frame size based on the
189// negotiated MaxPayload. This mirrors the server-side wsMaxMessageSize logic.

Callers 7

TestWSReaderFunction · 0.85
TestWSParseControlFramesFunction · 0.85
TestWSParseInvalidFramesFunction · 0.85
wsInitHandshakeMethod · 0.85

Calls

no outgoing calls

Tested by 6

TestWSReaderFunction · 0.68
TestWSParseControlFramesFunction · 0.68
TestWSParseInvalidFramesFunction · 0.68