From 588295e1e541b438af17db985887ffcef71121bf Mon Sep 17 00:00:00 2001 From: sehraf Date: Sat, 25 Aug 2018 16:52:46 +0200 Subject: [PATCH] make RsGroupInfo serializable --- libretroshare/src/retroshare/rspeers.h | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) diff --git a/libretroshare/src/retroshare/rspeers.h b/libretroshare/src/retroshare/rspeers.h index 01fb7ba8d..a77a5c4b3 100644 --- a/libretroshare/src/retroshare/rspeers.h +++ b/libretroshare/src/retroshare/rspeers.h @@ -293,16 +293,25 @@ public: std::string cipher_version; }; -class RsGroupInfo +class RsGroupInfo : RsSerializable { public: - RsGroupInfo(); + RsGroupInfo(); - RsNodeGroupId id; - std::string name; - uint32_t flag; + RsNodeGroupId id; + std::string name; + uint32_t flag; - std::set peerIds; + std::set peerIds; + + // RsSerializable interface +public: + void serial_process(RsGenericSerializer::SerializeJob j, RsGenericSerializer::SerializeContext &ctx) { + RS_SERIAL_PROCESS(id); + RS_SERIAL_PROCESS(name); + RS_SERIAL_PROCESS(flag); + RS_SERIAL_PROCESS(peerIds); + } }; std::ostream &operator<<(std::ostream &out, const RsPeerDetails &detail);