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

Method ReadByte

ws.go:150–158  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

148}
149
150func (d *wsDecompressor) ReadByte() (byte, error) {
151 if len(d.bufs) == 0 {
152 return 0, io.EOF
153 }
154 b := d.bufs[0][d.off]
155 d.off++
156 d.nextBuf()
157 return b, nil
158}
159
160func (d *wsDecompressor) addBuf(b []byte) {
161 d.bufs = append(d.bufs, b)

Callers 1

TestWSDecompressorFunction · 0.95

Calls 1

nextBufMethod · 0.95

Tested by 1

TestWSDecompressorFunction · 0.76