added reading start
This commit is contained in:
parent
5d2a0f867c
commit
d438feb9ee
7 changed files with 128 additions and 4 deletions
|
|
@ -25,3 +25,9 @@ std::string StringReader::readString(size_t len) {
|
|||
if (static_cast<size_t>(got) < len) s.resize(static_cast<size_t>(got));
|
||||
return s;
|
||||
}
|
||||
|
||||
std::string StringReader::readLine() {
|
||||
std::string s;
|
||||
if (!std::getline(in, s)) return std::string();
|
||||
return s;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue