Function in io::sync coil-stdlib

read_to_end

fn read_to_end(Stream s) -> Result<Vec<byte>, IoError>
Import
use io::sync::{read_to_end};
Source: src/io/sync.hy

Reads from s until it ends and returns everything read.

Parameters#

NameType
sStream

Returns#

Result<Vec<byte>, IoError>

See also#

  • write_all: Writes all of buf to s, waiting whenever the stream is not ready.
  • read_exact: Fills all of buf from s, waiting whenever no data is ready.
  • accept_wait: Waits for the next connection on a TCP listener and returns its stream.
  • recv_from_wait: Waits for a UDP datagram, reads it into buf, and returns (bytes, sender host, sender port).
  • send_to_wait: Sends buf as one UDP datagram to host:port, waiting while the socket is not ready.
  • copy: Copies the file src to dst.
  • print: Writes s to standard output, without a newline.
  • println: Writes s and a newline to standard output.
↑ ↓ navigate ↵ open