aboutsummaryrefslogtreecommitdiff
path: root/src/main/input-output/input/json-parsing/json_helper.h
diff options
context:
space:
mode:
authorTom Harley2019-01-27 15:37:06 +0000
committerTom Harley2019-01-27 15:37:06 +0000
commita996283af7c21baaff0e114d58c34db820902c6f (patch)
tree2fe5b6f7a800d4a7b8a65ee345f8c98aa138e36b /src/main/input-output/input/json-parsing/json_helper.h
parentSplit code into 3 files (diff)
downloadmetasol-a996283af7c21baaff0e114d58c34db820902c6f.tar.gz
metasol-a996283af7c21baaff0e114d58c34db820902c6f.zip

Reorganise repo

All solvitaire content has been shoved into a subdirectory to tidy up the root of the project. This also means solvitaire is treated similarly to other dependencies of the project, and allows other dependencies to be added easily.

There’s also a lot of other work done here, such as usign a thread pool library to manage the running of the voters.

Diffstat (limited to 'src/main/input-output/input/json-parsing/json_helper.h')
-rw-r--r--src/main/input-output/input/json-parsing/json_helper.h31
1 files changed, 0 insertions, 31 deletions
diff --git a/src/main/input-output/input/json-parsing/json_helper.h b/src/main/input-output/input/json-parsing/json_helper.h
deleted file mode 100644
index 460911f..0000000
--- a/src/main/input-output/input/json-parsing/json_helper.h
+++ /dev/null
@@ -1,31 +0,0 @@
-//
-// Created by thecharlesblake on 11/13/17.
-//
-
-#ifndef SOLVITAIRE_UTIL_H
-#define SOLVITAIRE_UTIL_H
-
-#include <string>
-
-#include <boost/property_tree/ptree.hpp>
-#include <boost/property_tree/json_parser.hpp>
-
-#include "../../../../../lib/rapidjson/schema.h"
-#include "../../../game/search-state/game_state.h"
-
-class json_helper {
-public:
- static rapidjson::Document get_file_json(const std::string&);
- static void json_parse_warning(const std::string& msg);
- static void json_parse_err(const std::string& msg);
- static const std::string schema_err_str(const rapidjson::SchemaValidator&);
- static void print_game_state_as_json(const game_state&);
-private:
- static boost::property_tree::ptree piles_to_ptree(const game_state&, const std::list<pile::ref>&);
- static boost::property_tree::ptree piles_to_ptree(const game_state&, const std::vector<pile::ref>&);
- static boost::property_tree::ptree pile_to_ptree(const pile&);
- static boost::property_tree::ptree card_to_ptree(const card&);
-};
-
-
-#endif //SOLVITAIRE_UTIL_H