fileapi: Add helper to create and reference a json reply file

This commit is contained in:
Brad King
2018-10-24 15:22:54 -04:00
parent 276fdf2993
commit 7ee0abbde1
2 changed files with 17 additions and 0 deletions

View File

@@ -31,6 +31,11 @@ public:
/** Get the "cmake" instance with which this was constructed. */
cmake* GetCMakeInstance() const { return this->CMakeInstance; }
/** Convert a JSON object or array into an object with a single
"jsonFile" member specifying a file named with the given prefix
and holding the original object. Other JSON types are unchanged. */
Json::Value MaybeJsonFile(Json::Value in, std::string const& prefix);
private:
cmake* CMakeInstance;