7 #include "fwGdcmIO/helper/CsvIO.hpp" 11 #include <boost/tokenizer.hpp> 37 typedef ::boost::char_separator<char> CharSeparatorType;
38 typedef ::boost::tokenizer< CharSeparatorType > TokenizerType;
46 const CharSeparatorType sep(separator.c_str(),
"", ::boost::keep_empty_tokens);
48 if(std::getline(m_stream, line))
50 TokenizerType tokenizer(line, sep);
51 tokens.assign(tokenizer.begin(), tokenizer.end());
FWGDCMIO_API TokenContainerType getLine(const std::string &separator=",")
Returns tokens on next line to read, using comma separator.
FWGDCMIO_API CsvIO(std::istream &csvStream)
Constructor.
The namespace fwGdcmIO contains reader, writer and helper for dicom data.
virtual FWGDCMIO_API ~CsvIO()
Desctructor.
std::vector< std::string > TokenContainerType
Containers to store parsed tokens.
This file defines SpyLog macros. These macros are used to log messages to a file or to the console du...