BitmapCursor
class BitmapCursor
A walk over a bitmap's ordinals, ascending.
val cursor = bitmap.cursor()
while (cursor.next()) { /* cursor.value */}Content copied to clipboard
Owns nothing and closes nothing — but a cursor over a BitmapView reads through the view's mapping, so it lives under the same rule the view does: it must not outlive the arena that mapped the file.
advanceTo is what makes an index intersection cheaper than a merge. Walking two bitmaps from the start costs the sum of their cardinalities; walking the sparser one and jumping the denser costs the sparser, which is the difference between reading a sidecar and reading past it.