Define an is_serializable trait for types we can serialize natively. More...
#include "Config.hh"
#include "Boost.hh"
#include "Types.hh"
Go to the source code of this file.
Classes | |
struct | avro::is_serializable< T > |
struct | avro::is_promotable< T > |
struct | avro::type_to_avro< T > |
Namespaces | |
namespace | avro |
A bunch of templates and specializations for encoding and decoding specific types. | |
Defines | |
#define | DEFINE_PRIMITIVE(CTYPE, AVROTYPE) |
#define | DEFINE_PROMOTABLE_PRIMITIVE(CTYPE, AVROTYPE) |
Define an is_serializable trait for types we can serialize natively.
New types will need to define the trait as well.
#define DEFINE_PRIMITIVE | ( | CTYPE, | ||
AVROTYPE | ||||
) |
template <> \ struct is_serializable<CTYPE> : public boost::true_type{}; \ \ template <> \ struct type_to_avro<CTYPE> { \ static const Type type = AVROTYPE; \ };
#define DEFINE_PROMOTABLE_PRIMITIVE | ( | CTYPE, | ||
AVROTYPE | ||||
) |
template <> \ struct is_promotable<CTYPE> : public boost::true_type{}; \ \ DEFINE_PRIMITIVE(CTYPE, AVROTYPE)