This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

a question about inheriting from std::iostream


I'm not sure if this question has been asked and i couldn't find an
example in all of my searches. But I'd like to write a class that would
perform substitution of keywords while some other class is reading from
it. 
  I was thinking about getting streambuf from ios::rdbuf() and
performing all the substitutions and then setting it back but that
approach make take some time with big files. If my understanding is
correct about how streambuf class works.
  Can anybody suggest a way of inheriting from iostream and doing the
substitution on-the-fly ?



Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]