(data []byte)
| 59 | } |
| 60 | |
| 61 | func readKeyFromEntry(data []byte) string { |
| 62 | length := binary.LittleEndian.Uint16(data[timestampSizeInBytes+hashSizeInBytes:]) |
| 63 | |
| 64 | // copy on read |
| 65 | dst := make([]byte, length) |
| 66 | copy(dst, data[headersSizeInBytes:headersSizeInBytes+length]) |
| 67 | |
| 68 | return bytesToString(dst) |
| 69 | } |
| 70 | |
| 71 | func compareKeyFromEntry(data []byte, key string) bool { |
| 72 | length := binary.LittleEndian.Uint16(data[timestampSizeInBytes+hashSizeInBytes:]) |
searching dependent graphs…