MCPcopy Create free account
hub / github.com/WinMerge/winmerge / parseCharInputStream

Method parseCharInputStream

Externals/poco/XML/src/ParserEngine.cpp:294–308  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

292
293
294void ParserEngine::parseCharInputStream(XMLCharInputStream& istr)
295{
296 std::streamsize n = readChars(istr, reinterpret_cast<XMLChar*>(_pBuffer), PARSE_BUFFER_SIZE/sizeof(XMLChar));
297 while (n > 0)
298 {
299 if (!XML_Parse(_parser, _pBuffer, static_cast<int>(n*sizeof(XMLChar)), 0))
300 handleError(XML_GetErrorCode(_parser));
301 if (istr.good())
302 n = readChars(istr, reinterpret_cast<XMLChar*>(_pBuffer), PARSE_BUFFER_SIZE/sizeof(XMLChar));
303 else
304 n = 0;
305 }
306 if (!XML_Parse(_parser, _pBuffer, 0, 1))
307 handleError(XML_GetErrorCode(_parser));
308}
309
310
311void ParserEngine::parseExternal(XML_Parser extParser, InputSource* pInputSource)

Callers

nothing calls this directly

Calls 3

XML_ParseFunction · 0.85
XML_GetErrorCodeFunction · 0.85
goodMethod · 0.45

Tested by

no test coverage detected