json_fwd.hpp 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. #ifndef INCLUDE_NLOHMANN_JSON_FWD_HPP_
  2. #define INCLUDE_NLOHMANN_JSON_FWD_HPP_
  3. #include <cstdint> // int64_t, uint64_t
  4. #include <map> // map
  5. #include <memory> // allocator
  6. #include <string> // string
  7. #include <vector> // vector
  8. /*!
  9. @brief namespace for Niels Lohmann
  10. @see https://github.com/nlohmann
  11. @since version 1.0.0
  12. */
  13. namespace nlohmann
  14. {
  15. /*!
  16. @brief default JSONSerializer template argument
  17. This serializer ignores the template arguments and uses ADL
  18. ([argument-dependent lookup](https://en.cppreference.com/w/cpp/language/adl))
  19. for serialization.
  20. */
  21. template<typename T = void, typename SFINAE = void>
  22. struct adl_serializer;
  23. template<template<typename U, typename V, typename... Args> class ObjectType =
  24. std::map,
  25. template<typename U, typename... Args> class ArrayType = std::vector,
  26. class StringType = std::string, class BooleanType = bool,
  27. class NumberIntegerType = std::int64_t,
  28. class NumberUnsignedType = std::uint64_t,
  29. class NumberFloatType = double,
  30. template<typename U> class AllocatorType = std::allocator,
  31. template<typename T, typename SFINAE = void> class JSONSerializer =
  32. adl_serializer,
  33. class BinaryType = std::vector<std::uint8_t>>
  34. class basic_json;
  35. /*!
  36. @brief JSON Pointer
  37. A JSON pointer defines a string syntax for identifying a specific value
  38. within a JSON document. It can be used with functions `at` and
  39. `operator[]`. Furthermore, JSON pointers are the base for JSON patches.
  40. @sa [RFC 6901](https://tools.ietf.org/html/rfc6901)
  41. @since version 2.0.0
  42. */
  43. template<typename BasicJsonType>
  44. class json_pointer;
  45. /*!
  46. @brief default JSON class
  47. This type is the default specialization of the @ref basic_json class which
  48. uses the standard template types.
  49. @since version 1.0.0
  50. */
  51. using json = basic_json<>;
  52. } // namespace nlohmann
  53. #endif // INCLUDE_NLOHMANN_JSON_FWD_HPP_