2018-01-10 17:18:31 +08:00
|
|
|
#pragma once
|
2017-08-14 23:18:07 +08:00
|
|
|
|
2018-01-29 18:21:11 +08:00
|
|
|
#include <nlohmann/detail/iterators/primitive_iterator.hpp>
|
2017-08-14 23:18:07 +08:00
|
|
|
|
|
|
|
namespace nlohmann
|
|
|
|
{
|
|
|
|
namespace detail
|
|
|
|
{
|
|
|
|
/*!
|
|
|
|
@brief an iterator value
|
|
|
|
|
|
|
|
@note This structure could easily be a union, but MSVC currently does not allow
|
|
|
|
unions members with complex constructors, see https://github.com/nlohmann/json/pull/105.
|
|
|
|
*/
|
|
|
|
template<typename BasicJsonType> struct internal_iterator
|
|
|
|
{
|
|
|
|
/// iterator for JSON objects
|
|
|
|
typename BasicJsonType::object_t::iterator object_iterator {};
|
|
|
|
/// iterator for JSON arrays
|
|
|
|
typename BasicJsonType::array_t::iterator array_iterator {};
|
2019-07-05 12:13:25 +08:00
|
|
|
/// iterator for JSON binary arrays
|
|
|
|
typename BasicJsonType::binary_t::iterator binary_iterator {};
|
2017-08-14 23:18:07 +08:00
|
|
|
/// generic iterator for all other types
|
|
|
|
primitive_iterator_t primitive_iterator {};
|
|
|
|
};
|
2018-10-08 00:39:18 +08:00
|
|
|
} // namespace detail
|
|
|
|
} // namespace nlohmann
|