(b []byte)
| 1002 | } |
| 1003 | |
| 1004 | func decodeTimeTZ(b []byte) ([]byte, int64, int32, error) { |
| 1005 | if PeekType(b) != TimeTZ { |
| 1006 | return nil, 0, 0, errors.Errorf("did not find marker") |
| 1007 | } |
| 1008 | b = b[1:] |
| 1009 | var err error |
| 1010 | var unixMicros int64 |
| 1011 | b, unixMicros, err = DecodeVarintAscending(b) |
| 1012 | if err != nil { |
| 1013 | return nil, 0, 0, err |
| 1014 | } |
| 1015 | var offsetSecs int64 |
| 1016 | b, offsetSecs, err = DecodeVarintAscending(b) |
| 1017 | if err != nil { |
| 1018 | return nil, 0, 0, err |
| 1019 | } |
| 1020 | return b, unixMicros, int32(offsetSecs), nil |
| 1021 | } |
| 1022 | |
| 1023 | // EncodeDurationAscending encodes a duration.Duration value, appends it to the |
| 1024 | // supplied buffer, and returns the final buffer. The encoding is guaranteed to |
no test coverage detected
searching dependent graphs…