SST/macro
Classes | Namespaces | Macros
serializable.h File Reference
#include <sprockit/serializable_type.h>
#include <sprockit/unordered.h>
#include <typeinfo>
#include <stdint.h>
#include <sprockit/serialize_serializable.h>
Include dependency graph for serializable.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  sprockit::serializable_builder
 
class  sprockit::serializable_builder_impl< T >
 
class  sprockit::serializable_factory
 

Namespaces

 sprockit
 

Macros

#define ImplementVirtualSerializable(obj)
 
#define NotSerializable(obj)
 
#define ImplementSerializableDefaultConstructor(obj)
 
#define ImplementSerializable(obj)
 
#define DeclareSerializable(...)
 

Macro Definition Documentation

#define DeclareSerializable (   ...)

Definition at line 175 of file serializable.h.

#define ImplementSerializable (   obj)
Value:
public: \
#define ImplementSerializableDefaultConstructor(obj)
Definition: serializable.h:58

Definition at line 77 of file serializable.h.

#define ImplementSerializableDefaultConstructor (   obj)
Value:
public: \
virtual const char* \
cls_name() const { \
return #obj; \
} \
virtual uint32_t \
cls_id() const { \
return ::sprockit::serializable_builder_impl< obj >::static_cls_id(); \
} \
static obj* \
construct_deserialize_stub() { \
return new obj; \
} \
virtual obj* \
you_forgot_to_add_ImplementSerializable_to_this_class() { \
return 0; \
} \

Definition at line 58 of file serializable.h.

#define ImplementVirtualSerializable (   obj)
Value:
protected: \
obj(cxn_flag_t flag){}

Definition at line 22 of file serializable.h.

#define NotSerializable (   obj)
Value:
public: \
static void \
throw_exc(){ \
"type %s should not be serialized", \
#obj); \
} \
virtual void \
serialize_order(sprockit::serializer& sst){ \
throw_exc(); \
} \
virtual uint32_t \
cls_id() const { \
throw_exc(); \
return -1; \
} \
static obj* \
construct_deserialize_stub() { \
throw_exc(); \
return 0; \
} \
virtual const char* \
cls_name() const { \
throw_exc(); \
return ""; \
} \
virtual obj* \
you_forgot_to_add_ImplementSerializable_to_this_class() { \
return 0; \
} \
An error indicating some format was not correct.
Definition: errors.h:131
This class is basically a wrapper for objects to declare the order in which their members should be s...
Definition: serializer.h:33
#define spkt_throw_printf(exc, template_str,...)
Definition: errors.h:37

Definition at line 26 of file serializable.h.

Referenced by sstmac::hw::packetizer::packetizer().