TurtleBrains  0.3.5
High quality, portable, C++ framework for rapid 2D game development.
tb_json_parser.hpp
1 
8 #ifndef TurtleBrains_JsonParser_hpp
9 #define TurtleBrains_JsonParser_hpp
10 
11 #include <turtle_brains/core/tb_string.hpp>
12 #include <turtle_brains/core/tb_dynamic_structure.hpp>
13 
14 #include <ostream>
15 
16 namespace TurtleBrains
17 {
18  namespace Core
19  {
20 
22  tbCore::tbString EscapeJsonString(const tbCore::tbString& input);
23 
31  DynamicStructure ParseJson(const tbCore::tbString& jsonData);
32 
39  DynamicStructure LoadJsonFile(const tbCore::tbString& filepath);
40 
44  bool SaveJsonFile(const tbCore::tbString& filepath, const DynamicStructure& saveData, bool prettyJson = true);
45 
52 
68  tbCore::tbString GetChildFilepath(const tbCore::tbString& parentFilename, const tbCore::tbString& childFilename);
69 
70  }; /* namespace Core */
71 }; /* namespace TurtleBrains */
72 
73 namespace tbCore = TurtleBrains::Core;
74 
75 #endif /* TurtleBrains_JsonParser_hpp */
bool SaveJsonFile(const tbCore::tbString &filepath, const DynamicStructure &saveData, bool prettyJson=true)
Here is some information about the primary namespace.
Definition: tb_application_dialog.hpp:21
tbCore::tbString GetChildFilepath(const tbCore::tbString &parentFilename, const tbCore::tbString &childFilename)
DynamicStructure ParseJson(const tbCore::tbString &jsonData)
tbCore::tbString GetPathFromFilepath(const tbCore::tbString &filepath)
DynamicStructure LoadJsonFile(const tbCore::tbString &filepath)
Contains core functionality for each component of the API.
Definition: tb_debug_logger.hpp:88
std::string tbString
Definition: tb_string.hpp:335