ByteDurableDb.snapshot.root.cursor.open.copied: def of mylsm-lsm-store@0.6.0.1 Import: import mylsm-lsm-store@0.6.0.1/src/ByteDurableDb.bend as ByteDurableDb Lines 2794-2813 of mylsm-lsm-store@0.6.0.1/src/ByteDurableDb.bend: https://jend.leeeet.dev/read.txt?path=mylsm-lsm-store@0.6.0.1/src/ByteDurableDb.bend&start_line=2794&end_line=2813 import Base import mylsm-lsm-store@0.6.0.1/src/scan/SstCursor.bend as SstCursor import mylsm-lsm-store@0.6.0.1/src/scan/RangeCursor.bend as RangeCursor import mylsm-lsm-store@0.6.0.1/src/scan/VisibleCursor.bend as VisibleCursor def snapshot.root.cursor.open.copied( bounds: RangeCursor.Bounds & RangeCursor.Bounds, root: SnapshotRoot ) -> IO(Result<&1, &1, Error, SnapshotCursorRoot>): match bounds: case (visible_bounds, sst_bounds): match root: case SnapshotRoot{sst_path, _, retained_bytes, delta}: match sst_path: case None{}: IO.pure(Result<&1, &1, Error, SnapshotCursorRoot>, Done{SnapshotCursorRoot{retained_bytes, VisibleCursor.open(None{}, delta, visible_bounds)}}) case Some{path}: do IO>: opened : Result<&1, &1, U32 & String, SstCursor.Cursor> <- SstCursor.open.trusted(path, snapshot.root.sst.bounds(sst_bounds)) snapshot.root.cursor.opened(retained_bytes, delta, visible_bounds, opened) Uses (18): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO.bind https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=IO.pure https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Maybe https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Pair https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Result https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Sigma https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=String https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/src/ByteDurableDb.bend&name=Error https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/src/ByteDurableDb.bend&name=SnapshotCursorRoot https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/src/ByteDurableDb.bend&name=SnapshotRoot https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/src/ByteDurableDb.bend&name=snapshot.root.cursor.opened https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/src/ByteDurableDb.bend&name=snapshot.root.sst.bounds https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/src/scan/RangeCursor.bend&name=Bounds https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/src/scan/SstCursor.bend&name=Cursor https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/src/scan/SstCursor.bend&name=open.trusted https://jend.leeeet.dev/definition.txt?path=mylsm-lsm-store@0.6.0.1/src/scan/VisibleCursor.bend&name=open