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

Function GetCodecV2

encoding/encoding_v2.go:78–81  ·  view source on GitHub ↗

GetCodecV2 gets a registered CodecV2 by content-subtype, or nil if no CodecV2 is registered for the content-subtype. The content-subtype is expected to be lowercase.

(contentSubtype string)

Source from the content-addressed store, hash-verified

76//
77// The content-subtype is expected to be lowercase.
78func GetCodecV2(contentSubtype string) CodecV2 {
79 c, _ := registeredCodecs[contentSubtype].(CodecV2)
80 return c
81}

Callers 8

getCodecFunction · 0.92
MarshalMethod · 0.92
UnmarshalMethod · 0.92
MarshalMethod · 0.92
UnmarshalMethod · 0.92
TestForceCodecNameMethod · 0.92

Calls

no outgoing calls

Tested by 7

MarshalMethod · 0.74
UnmarshalMethod · 0.74
MarshalMethod · 0.74
UnmarshalMethod · 0.74
TestForceCodecNameMethod · 0.74