MCPcopy Create free account
hub / github.com/OpenFodder/openfodder / get_string

Method get_string

Source/Utils/json.hpp:9965–9981  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

9963 */
9964 template<typename NumberType>
9965 bool get_string(const input_format_t format,
9966 const NumberType len,
9967 string_t& result)
9968 {
9969 bool success = true;
9970 for (NumberType i = 0; i < len; i++)
9971 {
9972 get();
9973 if (JSON_HEDLEY_UNLIKELY(!unexpect_eof(format, "string")))
9974 {
9975 success = false;
9976 break;
9977 }
9978 result.push_back(static_cast<typename string_t::value_type>(current));
9979 };
9980 return success;
9981 }
9982
9983 /*!
9984 @brief create a byte array by reading bytes from the input

Callers 1

sax_parse_internalMethod · 0.80

Calls 2

getFunction · 0.85
push_backMethod · 0.45

Tested by

no test coverage detected