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

Method Marshal

codec.go:69–75  ·  view source on GitHub ↗
(v any)

Source from the content-addressed store, hash-verified

67}
68
69func (c codecV0Bridge) Marshal(v any) (mem.BufferSlice, error) {
70 data, err := c.codec.Marshal(v)
71 if err != nil {
72 return nil, err
73 }
74 return mem.BufferSlice{mem.SliceBuffer(data)}, nil
75}
76
77func (c codecV0Bridge) Unmarshal(data mem.BufferSlice, v any) (err error) {
78 return c.codec.Unmarshal(data.Materialize(), v)

Callers

nothing calls this directly

Calls 2

SliceBufferTypeAlias · 0.92
MarshalMethod · 0.65

Tested by

no test coverage detected