All Manuals > LispWorks® User Guide and Reference Manual > 33 The COMMON-LISP Package

read-sequence

write-sequence Functions

Summary

Reads or writes a sequence from or to a stream.

Package

common-lisp

Signatures

read-sequence sequence input-stream &key start end => position

write-sequence sequence output-stream &key start end => sequence

Arguments
sequence
A sequence.
input-stream
An input stream.
start, end
Bounding index designators of sequence.
output-stream
An input stream.
Values
position
An index into sequence.
sequence
A sequence.
Description

The functions read-sequence and write-sequence read and write sequence, bounded by start and end from input-stream or to output-stream, as specified in the ANSI Common Lisp standard.

In LispWorks, read-sequence and write-sequence simply call stream:stream-read-sequence or stream:stream-write-sequence respectively, passing them all the arguments. This allows you to customize the implementation of read-sequence and write-sequence for your own stream classes by defining specialized methods.

See also

read-sequence in the Common Lisp HyperSpec
write-sequence in the Common Lisp HyperSpec
stream:stream-read-sequence
stream:stream-write-sequence


LispWorks® User Guide and Reference Manual - 01 Dec 2021 19:30:30