32 if (is.peek() != comment_char)
36 is.ignore(std::numeric_limits<std::streamsize>::max(),
'\n');
43 if (!line.empty() && *line.rbegin() ==
'\r')
45 line.resize(line.size()-1);
56 std::string out_str = ss.str();
57 out_str = out_str.substr(out_str.find_first_not_of(
" \t"));
64 std::ostringstream oss;
65 oss << std::setw(digits) << std::setfill(
'0') << i;
70 inline int to_int(
const std::string& str)
73 std::stringstream(str) >> i;
std::string to_string(int i)
void skip_comment_lines(std::istream &is, const char comment_char)
std::string to_padded_string(int i, int digits)
int to_int(const std::string &str)
void filter_dos(std::string &line)