std::stringstream
, and extol the virtues of making your classes streamable.
Posts: 32 / Nickname: cda / Registered: February 11, 2003 0:06 PM
Stream Thy Strings
May 28, 2005 8:00 AM
|
In this tutorial, Bjorn and Matthew
show the proper use of std::stringstream, and extol the virtues of making your classes streamable. http://www.artima.com/cppsource/streamstrings.html |
Posts: 1 / Nickname: danio / Registered: May 31, 2005 10:49 PM
Re: Stream Thy Strings
June 1, 2005 2:57 AM
|
There is a mistake in the URL for reference 6 - there should be no space before the n in wilson.
An interesting article and something I would like to work on as our current code uses scanf and printf for ascii file i/o. Looking forward to more information on istringstream and especially techniques for implementing operator>> for classes. |
Posts: 9 / Nickname: bfk / Registered: August 4, 2004 9:28 AM
Re: Stream Thy Strings
June 2, 2005 10:39 AM
|
Hello Dan,
> There is a mistake in the URL for reference 6 - there > should be no space before the n in wilson. Thanks for spotting that one! > An interesting article and something I would like to work > on as our current code uses scanf and printf for ascii > file i/o. Sounds like a good idea. The IOStreams library is very powerful, yet sadly underused. > Looking forward to more information on istringstream and > especially techniques for implementing operator>> for > classes. We'll do our best! Cheers, Bjorn |