XLISP > XLISP 2.0  -  Contents  -  Reference  -  Previous | Next

get-output-stream-list


Type:   -   function (subr)
Source:   -   xlfio.c

Syntax

(get-output-stream-list stream)
stream - an output stream expression
returns - the output so far as a list

Description

The 'get-output-stream-list' function empties the specified 'stream' and returns this data as a list. The output stream is emptied by this operation.

Examples

(setq out (make-string-output-stream))  ; returns #<Unnamed-Stream: #...>

(format out "123")                      ; add some data to output stream
(get-output-stream-list out)            ; returns (#\1 #\2 #\3)

(format out "123")                      ; add some data to output stream
(read out)                              ; returns 123
(get-output-stream-list out)            ; returns NIL, the string was emptied by 'read'

See the get-output-stream-list function in the XLISP 2.0 manual.

  Back to Top


XLISP > XLISP 2.0  -  Contents  -  Reference  -  Previous | Next