MCPcopy Create free account
hub / github.com/clechasseur/pathcopycopy / ReadString

Method ReadString

PathCopyCopy/src/PluginPipelineDecoder.cpp:521–529  ·  view source on GitHub ↗

Reads an encoded string from the elements stream. @return String value.

Source from the content-addressed store, hash-verified

519 // @return String value.
520 //
521 auto PipelineDecoder::EncodedElementsStream::ReadString() -> std::wstring
522 {
523 // First is encoded string size.
524 const auto stringSize = gsl::narrow<std::wstring::size_type>(ReadLong());
525
526 // Now that we know the length of the string that is encoded, we simply
527 // need to copy that much characters from the encoded string.
528 return ReadData(stringSize);
529 }
530
531 //
532 // Reads an encoded boolean value from the elements stream.

Calls

no outgoing calls

Tested by

no test coverage detected