MCPcopy Create free account
hub / github.com/imroc/req / WriteData

Method WriteData

internal/http2/frame.go:709–711  ·  view source on GitHub ↗

writeData writes a DATA frame. It will perform exactly one Write to the underlying Writer. It is the caller's responsibility not to violate the maximum frame size and to not call other Write methods concurrently.

(streamID uint32, endStream bool, data []byte)

Source from the content-addressed store, hash-verified

707// It is the caller's responsibility not to violate the maximum frame size
708// and to not call other Write methods concurrently.
709func (h2f *Framer) WriteData(streamID uint32, endStream bool, data []byte) error {
710 return h2f.WriteDataPadded(streamID, endStream, data, nil)
711}
712
713// WriteDataPadded writes a DATA frame with optional padding.
714//

Callers 2

TestFramerWriteReadDataFunction · 0.95
writeRequestBodyMethod · 0.80

Calls 1

WriteDataPaddedMethod · 0.95

Tested by 1

TestFramerWriteReadDataFunction · 0.76