MCPcopy Create free account
hub / github.com/google/codesearch / dumpPosting

Method dumpPosting

index/read.go:185–194  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

183}
184
185func (ix *Index) dumpPosting() {
186 d := ix.slice(ix.postIndex, postEntrySize*ix.numPost)
187 for i := 0; i < ix.numPost; i++ {
188 j := i * postEntrySize
189 t := uint32(d[j])<<16 | uint32(d[j+1])<<8 | uint32(d[j+2])
190 count := int(binary.BigEndian.Uint32(d[j+3:]))
191 offset := binary.BigEndian.Uint32(d[j+3+4:])
192 log.Printf("%#x: %d at %d", t, count, offset)
193 }
194}
195
196func (ix *Index) findList(trigram uint32) (count int, offset uint32) {
197 // binary search

Callers

nothing calls this directly

Calls 1

sliceMethod · 0.95

Tested by

no test coverage detected