ByteStream.h

Input/output classes

o class ByteStream: public GPEnabled
Abstract class for a stream of bytes.
Files "ByteStream.h" and "ByteStream.cpp" define input/output classes similar in spirit to the well known C++ ByteStream is an abstract base class for all byte streams. It defines a virtual interface and also provides useful functions. These files provide two subclasses. Class ByteStream::Stdio provides a simple interface to the Ansi C buffered input/output functions. Class ByteStream::Memory provides stream-like access to a dynamical array maintained in memory. Class ByteStream::Static provides read-only stream-like access to a user allocated data buffer.

Notes --- These classes were partly written because we did not want to depend on the standard C++ library. The main reason however is related to the browser interface. We want to have a tight control over the implementation of subclasses because we want to use a byte stream to represent data passed by a web browser to a plugin. This operation involves multi-threading issues that many implementations of the standard C++ library would squarely ignore.

Author:
Léon Bottou <leonb@research.att.com> -- initial implementation
Andrei Erofeev <eaf@geocities.com> --
Version:
$Id: ByteStream.h.html,v 1.12 2001/02/15 01:12:21 bcr Exp $

Alphabetic index Hierarchy of classes


DjVu is a trademark of LizardTech, Inc.
All other products mentioned are registered trademarks or trademarks of their respective companies.