Fwd: Concatenated input streams

Robert Dodier via Boost-users <[email protected]>
Newsgroups gmane.comp.lib.boost.user
Message-ID <CAAsY_sSBbN5JE4pXua7B3Z7_q7GbDTnw_2tBd4Q+pNr4Z7NhBw@mail.gmail.com>
Hi,

I'm interested in working with an input stream which comprises
multiple input streams. The resulting stream comprises all of the
input from the first stream (until EOF), then all of the input from
the second, etc. For what it's worth, such an input stream is called a
concatenated input stream in at least one other context (namely Common
Lisp).

The input streams in question are file input streams, although
conceptually I don't know if that changes anything. I am hoping to
find something equivalent to

$ cat file1 file2 file3 ... > alldata

and then reading alldata.

Is there a Boost class which implements such a thing? I know that this
is a pretty simple concept, and therefore it's just a small matter of
programming, but I'm hoping that someone has already worked out the
details.

If there is such a thing in some library other than Boost, I would be
interested to hear about that too.

Thank you for your time, I appreciate your help very much.

Robert Dodier
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.