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

Function wsIsControlFrame

ws.go:839–841  ·  view source on GitHub ↗

Returns true if the op code corresponds to a control frame.

(frameType wsOpCode)

Source from the content-addressed store, hash-verified

837
838// Returns true if the op code corresponds to a control frame.
839func wsIsControlFrame(frameType wsOpCode) bool {
840 return frameType >= wsCloseMessage
841}
842
843func isWebsocketScheme(u *url.URL) bool {
844 return u.Scheme == wsScheme || u.Scheme == wsSchemeTLS

Callers 1

ReadMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected