cesium-native  0.41.0
IJsonHandler.h
1 #pragma once
2 
3 #include "Library.h"
4 
5 #include <cstdint>
6 #include <string>
7 #include <string_view>
8 #include <vector>
9 
10 namespace CesiumJsonReader {
11 class CESIUMJSONREADER_API IJsonHandler {
12 public:
13  virtual ~IJsonHandler(){};
14  virtual IJsonHandler* readNull() = 0;
15  virtual IJsonHandler* readBool(bool b) = 0;
16  virtual IJsonHandler* readInt32(int32_t i) = 0;
17  virtual IJsonHandler* readUint32(uint32_t i) = 0;
18  virtual IJsonHandler* readInt64(int64_t i) = 0;
19  virtual IJsonHandler* readUint64(uint64_t i) = 0;
20  virtual IJsonHandler* readDouble(double d) = 0;
21  virtual IJsonHandler* readString(const std::string_view& str) = 0;
22  virtual IJsonHandler* readObjectStart() = 0;
23  virtual IJsonHandler* readObjectKey(const std::string_view& str) = 0;
24  virtual IJsonHandler* readObjectEnd() = 0;
25  virtual IJsonHandler* readArrayStart() = 0;
26  virtual IJsonHandler* readArrayEnd() = 0;
27 
28  virtual void reportWarning(
29  const std::string& warning,
30  std::vector<std::string>&& context = std::vector<std::string>()) = 0;
31 };
32 } // namespace CesiumJsonReader
Classes for reading JSON.