MCPcopy Create free account
hub / github.com/catboost/catboost / DoReadTo

Method DoReadTo

util/stream/input.cpp:20–41  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

18IInputStream::~IInputStream() = default;
19
20size_t IInputStream::DoReadTo(TString& st, char to) {
21 char ch;
22
23 if (!Read(&ch, 1)) {
24 return 0;
25 }
26
27 st.clear();
28
29 size_t result = 0;
30 do {
31 ++result;
32
33 if (ch == to) {
34 break;
35 }
36
37 st += ch;
38 } while (Read(&ch, 1));
39
40 return result;
41}
42
43ui64 IInputStream::DoReadAll(IOutputStream& out) {
44 TTempBuf buffer;

Callers

nothing calls this directly

Calls 2

ReadFunction · 0.50
clearMethod · 0.45

Tested by

no test coverage detected