MCPcopy
hub / github.com/grpc/grpc-go / idToPayload

Function idToPayload

binarylog/binarylog_end2end_test.go:122–124  ·  view source on GitHub ↗
(id int32)

Source from the content-addressed store, hash-verified

120)
121
122func idToPayload(id int32) *testpb.Payload {
123 return &testpb.Payload{Body: []byte{byte(id), byte(id >> 8), byte(id >> 16), byte(id >> 24)}}
124}
125
126func payloadToID(p *testpb.Payload) int32 {
127 if p == nil || len(p.Body) != 4 {

Callers 4

doUnaryCallMethod · 0.70
doClientStreamCallMethod · 0.70
doServerStreamCallMethod · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected