Next Previous Up Top Contents Index

17 The STREAM package

stream-read-sequence

Generic Function

Summary

Reads a number of items from a stream into a sequence.
Package

stream

Signature

stream-read-sequence stream sequence start end => index

Arguments

stream

A stream.

sequence

A sequence.

start

An integer.

end

An integer.

Values

index

An integer.

Description

The generic functionstream-read-sequence reads from stream into sequence. Elements from the start of sequence are replaced by elements from stream until end in sequence or the end-of-file in stream is reached. The index of the first element in sequence that is not replaced is returned.
A default method is provided byfundamental-character-input-stream which makes repeated calls tostream-read-char and uses(setf elt) to insert characters into sequence. A default method is provided byfundamental-binary-input-stream that makes repeated calls tostream-read-byte and also uses(setf elt) to insert bytes into sequence. Note that this may lead to error if the sequence is of inappropriate type.
See also

fundamental-binary-input-stream
fundamental-character-input-stream
stream-read-byte
stream-read-char

LispWorks Reference Manual - 15 Oct 1998

Next Previous Up Top Contents Index

Generated with Harlequin WebMaker