Unmarshal json decode
(data []byte, value interface{})
| 21 | |
| 22 | // Unmarshal json decode |
| 23 | func (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 |
| 32 | type JSONGzipEncoding struct{} |