MCPcopy
hub / github.com/pingcap/tidb / encodeCommonHandle

Function encodeCommonHandle

pkg/tablecodec/tablecodec.go:1820–1826  ·  view source on GitHub ↗
(idxVal []byte, h kv.Handle)

Source from the content-addressed store, hash-verified

1818}
1819
1820func encodeCommonHandle(idxVal []byte, h kv.Handle) []byte {
1821 idxVal = append(idxVal, CommonHandleFlag)
1822 hLen := uint16(len(h.Encoded()))
1823 idxVal = append(idxVal, byte(hLen>>8), byte(hLen))
1824 idxVal = append(idxVal, h.Encoded()...)
1825 return idxVal
1826}
1827
1828func encodePartitionID(idxVal []byte, partitionID int64) []byte {
1829 idxVal = append(idxVal, PartitionIDFlag)

Calls 1

EncodedMethod · 0.65

Tested by 1