Module Bi_stream
val read_stream : string -> 'a array -> Pervasives.in_channel -> 'a Stream.t
read_stream of_string ic
creates an OCaml stream from
an input channel ic
. The data come in chunks and each chunk
is converted from a string to an array by calling of_string
.
val write_stream : ?chunk_len:int -> 'a array -> string -> Pervasives.out_channel -> 'a Stream.t -> unit
write_stream to_string oc st
writes an OCaml stream to the
output channel oc
. It creates chunks of chunk_len
,
except for the last chunk which is usually smaller.
chunk_len has a default value of 1024. The limit
supported by this OCaml implementation on 32-bit
platforms is 16777215.
val test : int list -> bool