@brief returns the number of occurrences of a key in a JSON object @sa https://json.nlohmann.me/api/basic_json/count/
| 2738 | /// @brief returns the number of occurrences of a key in a JSON object |
| 2739 | /// @sa https://json.nlohmann.me/api/basic_json/count/ |
| 2740 | size_type count(const typename object_t::key_type& key) const |
| 2741 | { |
| 2742 | // return 0 for all nonobject types |
| 2743 | return is_object() ? m_data.m_value.object->count(key) : 0; |
| 2744 | } |
| 2745 | |
| 2746 | /// @brief returns the number of occurrences of a key in a JSON object |
| 2747 | /// @sa https://json.nlohmann.me/api/basic_json/count/ |
no test coverage detected