| Total Lines | 14 |
| Duplicated Lines | 0 % |
| Changes | 0 | ||
| 1 | package json |
||
| 2 | |||
| 3 | import ( |
||
| 4 | "github.com/bytedance/sonic" |
||
| 5 | ) |
||
| 6 | |||
| 7 | type SonicJSON struct{} |
||
| 8 | |||
| 9 | func (s *SonicJSON) Marshal(v interface{}) ([]byte, error) { |
||
| 10 | return sonic.Marshal(v) |
||
| 11 | } |
||
| 12 | |||
| 13 | func (s *SonicJSON) Unmarshal(data []byte, v interface{}) error { |
||
| 14 | return sonic.Unmarshal(data, v) |
||
| 15 | } |
||
| 16 |