MCPcopy Create free account
hub / github.com/cloudwego/netpoll / Slice

Method Slice

connection_impl.go:185–190  ·  view source on GitHub ↗

Slice implements Connection.

(n int)

Source from the content-addressed store, hash-verified

183
184// Slice implements Connection.
185func (c *connection) Slice(n int) (r Reader, err error) {
186 if err = c.waitRead(n); err != nil {
187 return nil, err
188 }
189 return c.inputBuffer.Slice(n)
190}
191
192// Len implements Connection.
193func (c *connection) Len() (length int) {

Callers

nothing calls this directly

Calls 2

waitReadMethod · 0.95
SliceMethod · 0.65

Tested by

no test coverage detected