cbor.go
raw| 1 | package utils |
| 2 | |
| 3 | // CBORMarshal returns the CBOR encoding of v. |
| 4 | type CBORMarshal func(v any) ([]byte, error) |
| 5 | |
| 6 | // CBORUnmarshal parses the CBOR-encoded data and stores the result |
| 7 | // in the value pointed to by v. If v is nil or not a pointer, |
| 8 | // Unmarshal returns an error. |
| 9 | type CBORUnmarshal func(data []byte, v any) error |