MCPcopy Index your code
hub / github.com/RoaringBitmap/roaring / init

Method init

roaring.go:701–719  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

699}
700
701func (ii *manyIntIterator) init() {
702 if ii.highlowcontainer.size() > ii.pos {
703 ii.hs = uint32(ii.highlowcontainer.getKeyAtIndex(ii.pos)) << 16
704 c := ii.highlowcontainer.getContainerAtIndex(ii.pos)
705 switch t := c.(type) {
706 case *arrayContainer:
707 ii.shortIter = shortIterator{t.content, 0}
708 ii.iter = &ii.shortIter
709 case *runContainer16:
710 ii.runIter = runIterator16{rc: t, curIndex: 0, curPosInIndex: 0}
711 ii.iter = &ii.runIter
712 case *bitmapContainer:
713 ii.bitmapIter = bitmapContainerManyIterator{t, -1, 0}
714 ii.iter = &ii.bitmapIter
715 }
716 } else {
717 ii.iter = nil
718 }
719}
720
721func (ii *manyIntIterator) NextMany(buf []uint32) int {
722 n := 0

Callers 3

NextManyMethod · 0.95
NextMany64Method · 0.95
InitializeMethod · 0.95

Calls 3

sizeMethod · 0.45
getKeyAtIndexMethod · 0.45
getContainerAtIndexMethod · 0.45

Tested by

no test coverage detected