sneak in serializer json stuff (header only, no dep tracking)
This commit is contained in:
parent
ce81ef7cf7
commit
bab367425f
14
solanaceae/tox_messages/nj/tox_message_components.hpp
Normal file
14
solanaceae/tox_messages/nj/tox_message_components.hpp
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include <solanaceae/tox_messages/components.hpp>
|
||||||
|
|
||||||
|
#include <nlohmann/json.hpp>
|
||||||
|
|
||||||
|
namespace Message::Components {
|
||||||
|
|
||||||
|
// TODO: friend msg id, does not have the same qualities
|
||||||
|
NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE(ToxGroupMessageID, id)
|
||||||
|
// TODO: transfer stuff, needs content rewrite
|
||||||
|
|
||||||
|
} // Message::Components
|
||||||
|
|
@ -0,0 +1,9 @@
|
|||||||
|
#pragma once
|
||||||
|
|
||||||
|
#include <solanaceae/message3/message_serializer.hpp>
|
||||||
|
|
||||||
|
inline void registerMessageComponents(MessageSerializerNJ& msnj) {
|
||||||
|
msnj.registerSerializer<Message::Components::ToxGroupMessageID>();
|
||||||
|
msnj.registerDeserializer<Message::Components::ToxGroupMessageID>();
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user