def entry.close

mylsm-lsm-store@0.6.0.1 · src/scan/ByteBlockReader.bend:1757

import mylsm-lsm-store@0.6.0.1/src/scan/ByteBlockReader.bend as ByteBlockReader
import Base

1757# Closes the active SST reader and preserves terminal cursor states.
1758def entry.close(cursor: EntryCursor) -> IO(Result<&1, &1, U32 & String, Unit>):
1759  match cursor:
1760    case EntryReady{reader, _}: close(reader)
1761    case EntryEnded{}:
1762      IO.pure(Result<&1, &1, U32 & String, Unit>, Done{Unit{}})
1763    case EntryClosed{}:
1764      IO.pure(Result<&1, &1, U32 & String, Unit>, Done{Unit{}})
1765    case EntryFailed{_}:
1766      IO.pure(Result<&1, &1, U32 & String, Unit>, Done{Unit{}})

Uses (9)

Used by (2)