Skip to content

Documentation / @etherfold/processor-entities / SnapshotDocument

Type Alias: SnapshotDocument ​

SnapshotDocument = Uint8Array | ArrayBuffer | ReadableStream<Uint8Array> | AsyncIterable<Uint8Array>

Defined in: packages/state-store/dist/snapshot-document.d.ts:169

A snapshot document as a host may hold it: bytes in hand, a response body, or any async source of byte chunks.

Either the GZIPPED document (what a publisher writes, and what a host serving the .gz opaque delivers) or the document already INFLATED (what a runtime hands over when the host served it with Content-Encoding: gzip). The reader tells them apart by the leading bytes and peels exactly one gzip layer.