Boost logo

Boost Users :

Subject: Re: [Boost-users] concat files for compression
From: Kraus Philipp (philipp.kraus_at_[hidden])
Date: 2010-06-15 16:06:07


Am 15.06.2010 um 21:37 schrieb Steven Watanabe:

> AMDG
>
> Kraus Philipp wrote:
>> Am 15.06.2010 um 18:08 schrieb Roland Bock:
>>>
>>> You could try to use std::copy like this (untested code):
>>>
>>> copy(istreambuf_iterator<char>(l_file), istreambuf_iterator<char>(),
>>> ostreambuf_iterator<char>(l_deflate));
>>
>> I have a problem with the thrid parameter, if I change it to
>> std::cout there're no problems, but my l_deflate is a
>> bio::filtering_streambuf< bio::output > and I can't convert it to a
>> std::ostreambuf_iterator<char> for the std::copy. I get the message:
>>
>> no matching function for call to 'std::ostream_iterator<char, char,
>> std::char_traits<char>
>> >
>> ::ostream_iterator
>> (boost::iostreams::filtering_streambuf<boost::iostreams::output,
>> char, std::char_traits<char>, std::allocator<char>,
>> boost::iostreams::public_>&)'
>>
>> Do you have any idea?
>
> Use std::ostreambuf_iterator instead std::ostream_iterator.

Thanks, now I can finished my normalized compression distance with
Boost :-) (I hope it works on MS systems also)
Many thanks to all

Phil


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net