jukebox
All repositories: gitoria
594 B
\* A lazy result cursor: each next() decodes ONE record. Handed out byMPackDB.cursor(); never `new`ed by app code. *\Hybrid #iter\* Next record, or null when exhausted. *\next() {return #iter.next()}\* Release what the cursor holds now (its snapshot). A `for` loop over a Cursor that is left bybreak/return calls this once (mission 418); calling it again, or after the end, is harmless. *\close() {if (#iter != null) { #iter.close() }}\* Remaining records as a Hybrid (consumes the cursor). *\all() {let out = []for (rec of #iter) {out.push(rec)}return out}