MCPcopy Create free account
hub / github.com/CalcProgrammer1/OpenRGB / max_size

Function max_size

dependencies/json/json.hpp:21648–21670  ·  view source on GitHub ↗

! @brief returns the maximum possible number of elements Returns the maximum number of elements a JSON value is able to hold due to system or library implementation limitations, i.e. `std::distance(begin(), end())` for the JSON value. @return The return value depends on the different types and is defined as follows: Value type | return value

Source from the content-addressed store, hash-verified

21646 @since version 1.0.0
21647 */
21648 size_type max_size() const noexcept
21649 {
21650 switch (m_type)
21651 {
21652 case value_t::array:
21653 {
21654 // delegate call to array_t::max_size()
21655 return m_value.array->max_size();
21656 }
21657
21658 case value_t::object:
21659 {
21660 // delegate call to object_t::max_size()
21661 return m_value.object->max_size();
21662 }
21663
21664 default:
21665 {
21666 // all other types have max_size() == size()
21667 return size();
21668 }
21669 }
21670 }
21671
21672 /// @}
21673

Callers

nothing calls this directly

Calls 1

sizeFunction · 0.70

Tested by

no test coverage detected