added SerializableStruct which defines serialize() and toPropertyTree()

This commit is contained in:
woodser
2019-06-07 09:26:03 -04:00
parent 1a0fd84872
commit 78eb67d4cb
4 changed files with 55 additions and 2 deletions
+24
View File
@@ -0,0 +1,24 @@
#include "utils/MoneroUtils.h"
#include <stdio.h>
#include <iostream>
#include "mnemonics/electrum-words.h"
#include "mnemonics/english.h"
using namespace cryptonote;
using namespace epee;
/**
* Public interface for libmonero-cpp library.
*/
namespace monero {
string SerializableStruct::serialize() {
boost::property_tree::ptree node;
toPropertyTree(node);
return MoneroUtils::serialize(node);
}
// ---------------------------- PRIVATE HELPERS -----------------------------
}