Streams
Streams
The Streams module processes data incrementally instead of requiring one complete in-memory string. It includes string-backed streams plus gzip/xz compression and decompression adapters.
Compression functions produce compressed output; zcat and xzcat decode compressed input. Choose the direction explicitly when composing import and export pipelines, and close externally owned resources according to the caller's IO contract.
streamString
creates a stream that contains a string
Allowed number of parameters: 1–1
Parameters
- content (
string): content to put into the stream
Returns
- value (
stream)
gzip
compresses a stream with gzip. Create streams with (stream filename)
Allowed number of parameters: 1–1
Parameters
- stream (
stream): input stream
Returns
- value (
stream)
xz
compresses a stream with xz. Create streams with (stream filename)
Allowed number of parameters: 1–1
Parameters
- stream (
stream): input stream
Returns
- value (
stream)
zcat
turns a compressed gzip stream into a stream of uncompressed data. Create streams with (stream filename)
Allowed number of parameters: 1–1
Parameters
- stream (
stream): input stream
Returns
- value (
stream)
xzcat
turns a compressed xz stream into a stream of uncompressed data. Create streams with (stream filename)
Allowed number of parameters: 1–1
Parameters
- stream (
stream): input stream
Returns
- value (
stream)