MCPcopy
hub / github.com/TarsCloud/TarsGo / ToBytes

Method ToBytes

tars/protocol/codec/codec.go:341–343  ·  view source on GitHub ↗

ToBytes make the buffer to []byte

()

Source from the content-addressed store, hash-verified

339
340// ToBytes make the buffer to []byte
341func (b *Buffer) ToBytes() []byte {
342 return b.buf.Bytes()
343}
344
345func (b *Buffer) Len() int {
346 return b.buf.Len()

Callers 15

req2ByteMethod · 0.95
rsp2ByteMethod · 0.95
RequestPackMethod · 0.95
response2BytesFunction · 0.95
GetTokensWithContextMethod · 0.95
ApplyTokenWithContextMethod · 0.95

Calls

no outgoing calls

Tested by 3

rFunction · 0.36
TestReader_ToBytesFunction · 0.36