def stream.blocks.decide
mylsm-lsm-store@0.6.0.1 · src/SstFile.bend:1180
import mylsm-lsm-store@0.6.0.1/src/SstFile.bend as SstFile
import Base
import bend-kit-bytes@0.3.2.0/bytes.bend as Bytes
1180
1181def stream.blocks.decide(
1182 state: BlockStreamState,
1183 records: ParsedEntries,
1184 +count: U32,
1185 digest: Bytes.Bytes,
1186 valid: Bool
1187) -> Result<&1, &1, Error, BlockStreamOutput>:
1188 match valid:
1189 case False{}:
1190 Fail{Malformed{}}
1191 case True{}:
1192 Done{stream.blocks.updated(state, records, count, digest)}