Hello
Suppose I have:
Here I dont have any problems figuring if the file is open or not, by doing:Code:boost::iostreams::file_source file_source_("somefile.txt"); boost::iostreams::filtering_istream filter_stream_; some_filter some_filter_; filter_stream_.push(boost::ref(some_filter_)); filter_stream_.push(boost::ref(file_source_));
Code:if (file_source_.is_open()) { }
But how can I tell if the file is_open() when I use boost iostreams this way (that I pass file_source as an object not as a reference):
Anyone knows how is that possible?Code:boost::iostreams::filtering_istream filter_stream_; some_filter some_filter_; filter_stream_.push(boost::ref(some_filter_)); filter_stream_.push(boost::iostreams::file_source("somefile.txt", std::ios::in | std::ios::binary));
Thanks a lot for help
Regards



LinkBack URL
About LinkBacks


