#include "jsonipc.hh"
Classes | |
class | InstanceWrapper |
class | Wrapper |
Public Types | |
using | CreateWrapper = Wrapper *(*)(const std::shared_ptr< SharedBase > &sptr, size_t &basedepth) |
using | IdSet = std::set< size_t > |
using | TypeidMap = std::map< TypeidKey, size_t > |
using | WrapperMap = std::unordered_map< size_t, Wrapper * > |
Public Member Functions | |
void | clear (const bool printdebug=false) |
bool | delete_id (size_t thisid) |
bool | empty () const |
bool | mark_unused () |
size_t | purge_unused (const std::vector< size_t > &unused) |
size_t | size () const |
virtual Wrapper * | wrapper_from_json (const JsonValue &value) |
virtual JsonValue | wrapper_to_json (Wrapper *wrapper, const size_t thisid, JsonAllocator &allocator) |
virtual | ~InstanceMap () |
Static Public Member Functions | |
static size_t | next_counter () |
static void | register_wrapper (CreateWrapper createwrapper) |
static bool | scope_forget_id (size_t thisid) |
static Wrapper * | scope_lookup_wrapper (const JsonValue &value) |
template<typename T > | |
static JsonValue | scope_wrap_object (const std::shared_ptr< T > &sptr, JsonAllocator &allocator) |
static std::vector< CreateWrapper > & | wrapper_creators () |
Public Attributes | |
IdSet * | idset_ |
TypeidMap | typeid_map_ |
WrapperMap | wmap_ |
using CreateWrapper = Wrapper* (*) (const std::shared_ptr<SharedBase> &sptr, size_t &basedepth) |
using WrapperMap = std::unordered_map<size_t, Wrapper*> |
using TypeidMap = std::map<TypeidKey, size_t> |
using IdSet = std::set<size_t> |
|
virtual |
|
static |
|
static |
|
static |
bool delete_id | ( | size_t | thisid | ) |
bool mark_unused | ( | ) |
size_t purge_unused | ( | const std::vector< size_t > & | unused | ) |
bool empty | ( | ) | const |
size_t size | ( | ) | const |
void clear | ( | const bool | printdebug = false | ) |
|
virtual |
|
static |
|
static |
WrapperMap wmap_ |
TypeidMap typeid_map_ |
IdSet* idset_ |