Electroneum
serializer< Archive< false >, boost::variant< BOOST_VARIANT_ENUM_PARAMS(T)> > Struct Template Reference

#include <variant.h>

Public Types

typedef boost::variant< BOOST_VARIANT_ENUM_PARAMS(T)> variant_type
 
typedef Archive< false >::variant_tag_type variant_tag_type
 
typedef variant_type::types types
 

Static Public Member Functions

static bool serialize (Archive< false > &ar, variant_type &v)
 

Detailed Description

template<template< bool > class Archive, BOOST_VARIANT_ENUM_PARAMS(typename T)>
struct serializer< Archive< false >, boost::variant< BOOST_VARIANT_ENUM_PARAMS(T)> >

Definition at line 106 of file variant.h.

Member Typedef Documentation

◆ types

template<template< bool > class Archive, BOOST_VARIANT_ENUM_PARAMS(typename T) >
typedef variant_type::types serializer< Archive< false >, boost::variant< BOOST_VARIANT_ENUM_PARAMS(T)> >::types

Definition at line 110 of file variant.h.

◆ variant_tag_type

template<template< bool > class Archive, BOOST_VARIANT_ENUM_PARAMS(typename T) >
typedef Archive<false>::variant_tag_type serializer< Archive< false >, boost::variant< BOOST_VARIANT_ENUM_PARAMS(T)> >::variant_tag_type

Definition at line 109 of file variant.h.

◆ variant_type

template<template< bool > class Archive, BOOST_VARIANT_ENUM_PARAMS(typename T) >
typedef boost::variant<BOOST_VARIANT_ENUM_PARAMS(T)> serializer< Archive< false >, boost::variant< BOOST_VARIANT_ENUM_PARAMS(T)> >::variant_type

Definition at line 108 of file variant.h.

Member Function Documentation

◆ serialize()

template<template< bool > class Archive, BOOST_VARIANT_ENUM_PARAMS(typename T) >
static bool serializer< Archive< false >, boost::variant< BOOST_VARIANT_ENUM_PARAMS(T)> >::serialize ( Archive< false > &  ar,
variant_type v 
)
inlinestatic

Definition at line 112 of file variant.h.

112  {
114  ar.begin_variant();
115  ar.read_variant_tag(t);
116  if(!variant_reader<Archive<false>, variant_type,
117  typename boost::mpl::begin<types>::type,
118  typename boost::mpl::end<types>::type>::read(ar, v, t))
119  {
120  ar.stream().setstate(std::ios::failbit);
121  return false;
122  }
123  ar.end_variant();
124  return true;
125  }
boost::variant< BOOST_VARIANT_ENUM_PARAMS(T)> variant_type
Definition: variant.h:108
reads a variant
Definition: variant.h:65

The documentation for this struct was generated from the following file: