
"Dietmar Kuehl" <dietmar_kuehl@yahoo.com> wrote in message news:200409031908.13053.dietmar_kuehl@yahoo.com...
|On the ACCU 2003 conference JC (I can figure out the full name if |necessary...) presented the idea for creating filters which I really |liked. It looked something like this:
|filter_stream out(tee(std::cout) | encode | gzip | file("some file"));
|This would create a stream which writes everything to 'std::cout' |and also encodes the stuff before sending it on to compress it and |finally write it to the file. I like this notation...
I second that
FWIW - I do NOT like this idea. I concede its mostly a matter of taste but I think it adds another layer of syntax. I think the original .. push, etc is ok. But my preference would be for filter_stream out( tee( std::out, encode( gzip( file("somefile") ) ) ) ) I'm sure people are going to love this idea. Robert Ramey