29#ifndef GPGFRONTEND_DATAOBJECTOPERATOR_H
30#define GPGFRONTEND_DATAOBJECTOPERATOR_H
32#include <json/single_include/nlohmann/json.hpp>
34#include "core/GpgFrontendCore.h"
35#include "core/GpgFunctionObject.h"
36#include "core/function/GlobalSettingStation.h"
51 std::string SaveDataObj(
const std::string &_key,
const nlohmann::json &value);
53 std::optional<nlohmann::json> GetDataObject(
const std::string &_key);
55 std::optional<nlohmann::json> GetDataObjectByRef(
const std::string &_ref);
62 void init_app_secure_key();
66 std::filesystem::path app_secure_path_ =
67 global_setting_station_.GetAppConfigPath() /
69 std::filesystem::path app_secure_key_path_ =
70 app_secure_path_ /
"app.key";
71 std::filesystem::path app_data_objs_path_ =
72 global_setting_station_.GetAppDataPath() /
"data_objs";
76 std::random_device
rd_;
77 std::mt19937 mt_ = std::mt19937(rd_());
Definition: DataObjectOperator.h:41
std::random_device rd_
Random device.
Definition: DataObjectOperator.h:76
QByteArray hash_key_
Hash key.
Definition: DataObjectOperator.h:78
Definition: GlobalSettingStation.h:48
Definition: GpgFunctionObject.h:49
static int GetDefaultChannel()
Get the Default Channel object.
Definition: GpgFunctionObject.h:127
static GlobalSettingStation & GetInstance(int channel=GpgFrontend::GPGFRONTEND_DEFAULT_CHANNEL)
Get the Instance object.
Definition: GpgFunctionObject.h:57
Definition: CoreCommonUtil.cpp:29