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

Method parse_bson_array

Source/Utils/json.hpp:8011–8027  ·  view source on GitHub ↗

! @brief Reads an array from the BSON input and passes it to the SAX-parser. @return whether a valid BSON-array was passed to the SAX parser */

Source from the content-addressed store, hash-verified

8009 @return whether a valid BSON-array was passed to the SAX parser
8010 */
8011 bool parse_bson_array()
8012 {
8013 std::int32_t document_size{};
8014 get_number<std::int32_t, true>(input_format_t::bson, document_size);
8015
8016 if (JSON_HEDLEY_UNLIKELY(!sax->start_array(std::size_t(-1))))
8017 {
8018 return false;
8019 }
8020
8021 if (JSON_HEDLEY_UNLIKELY(!parse_bson_element_list(/*is_array*/true)))
8022 {
8023 return false;
8024 }
8025
8026 return sax->end_array();
8027 }
8028
8029 //////////
8030 // CBOR //

Callers

nothing calls this directly

Calls 2

start_arrayMethod · 0.45
end_arrayMethod · 0.45

Tested by

no test coverage detected