Next Previous Up Top Contents Index

15 User Defined Streams

15.2 An illustrative example of user defined streams

In this chapter an example is provided to illustrate the main features of thestream package. In this example a stream class is defined to provide a wrapper forfile-stream which uses the Unicode Line Separator instead of the usual ASCII CR/LF combination to mark the end of lines in the file. Methods are then defined, specializing on the user defined stream class to ensure that it handles reading from and writing to a file correctly.

15.2.1 - Defining a new stream class
15.2.2 - Recognizing the stream element type
15.2.3 - Stream directionality
15.2.4 - Stream input
15.2.5 - Stream output
15.2.6 - Instantiating the stream

LispWorks User Guide - 14 Oct 1998

Next Previous Up Top Contents Index

Generated with Harlequin WebMaker