Boost logo

Boost :

From: Maxim Egorushkin (e-maxim_at_[hidden])
Date: 2003-07-14 14:31:21

"Jonathan D. Turkanis" <commerce_at_[hidden]> wrote in message

> I have posted a new version of my library, which has been rewritten to
> incorporate filtering as a basic construct.
> (
> In addition to allowing the easy creation of streams and streambuf from
> objects with socket-like interfaces, it provides a convenient interface
> defining i/o filters and for combining them in various ways with each
> and with types from the standard library (streams, streambufs, containers,
> sequences, codecvts.)

I don't get the idea of reinventing the stream classes. One can use their
rdbuf() member function to change the buffer. Could you please elaborate on

You have read/write member functions of your source/sink/filter concepts
virtual. If one went for efficiency she would stay away from virtual
functions. With such a design you leave a user no choice.

There are too many adapters, IMHO. It obscures. Since each STL sequence
support iterators why don't use it? Generally speaking, there should be only
two adapters (input and output) that take any STL sequence represented by
begin/end iterators.

P.S. There is a very good article by Alexandre Duret-Lutz and Thierry Geraud
Improving Object-Oriented Generic Programming". I took some damn good ideas
from there when I was implementing my buffer adapters. You can get it here:

Boost list run by bdawes at, gregod at, cpdaniel at, john at