+ /*!
+ * \brief reads a whole line
+ * \param in_stream - source stream
+ * \param next - if true, first reads the current line up to the end
+ * which is necessary after reading using >> operator
+ * \retval std::string - the result line
+ */
+ inline std::string read_line(std::ifstream& in_stream, const bool next=true)
+ {
+ char line[theMaxLineLen];
+ in_stream.getline( line, theMaxLineLen );
+ if ( next )
+ in_stream.getline( line, theMaxLineLen );
+
+ std::string resLine = line;
+ if ( resLine.size() > 0 && resLine[ resLine.size()-1 ] == '\r' )
+ resLine.resize( resLine.size()-1 );
+ return line;
+ }