MCPcopy Create free account
hub / github.com/go-dev-frame/sponge / Unmarshal

Method Unmarshal

pkg/encoding/json_encoding.go:23–29  ·  view source on GitHub ↗

Unmarshal json decode

(data []byte, value interface{})

Source from the content-addressed store, hash-verified

21
22// Unmarshal json decode
23func (j JSONEncoding) Unmarshal(data []byte, value interface{}) error {
24 err := json.Unmarshal(data, value)
25 if err != nil {
26 return err
27 }
28 return nil
29}
30
31// JSONGzipEncoding json and gzip
32type JSONGzipEncoding struct{}

Callers 2

TestEncodingErrorFunction · 0.95
BenchmarkJsonUnmarshalFunction · 0.95

Calls 1

UnmarshalMethod · 0.65

Tested by 2

TestEncodingErrorFunction · 0.76
BenchmarkJsonUnmarshalFunction · 0.76