! @brief exception indicating access out of the defined range This exception is thrown in case a library function is called on an input parameter that exceeds the expected range, for instance in case of array indices or nonexisting object keys. Exceptions have ids 4xx. name / id | example message | description -------
| 2609 | @since version 3.0.0 |
| 2610 | */ |
| 2611 | class out_of_range : public exception |
| 2612 | { |
| 2613 | public: |
| 2614 | static out_of_range create(int id_, const std::string& what_arg) |
| 2615 | { |
| 2616 | std::string w = exception::name("out_of_range", id_) + what_arg; |
| 2617 | return out_of_range(id_, w.c_str()); |
| 2618 | } |
| 2619 | |
| 2620 | private: |
| 2621 | JSON_HEDLEY_NON_NULL(3) |
| 2622 | out_of_range(int id_, const char* what_arg) : exception(id_, what_arg) {} |
| 2623 | }; |
| 2624 | |
| 2625 | /*! |
| 2626 | @brief exception indicating other library errors |
no outgoing calls
no test coverage detected