msgpack::detail Namespace Reference

## Classes

struct | all_of_imp
struct | any_of_imp
struct | bool_pack
class | context
class | create_object_visitor
struct | fix_tag
struct | packer_serializer
struct | parse_helper
struct | unpack_array
struct | unpack_map
class | unpack_stack
class | unpack_user
struct | value
struct | value< fix_tag >

## Functions

template<std::size_t N>
void | check_container_size (std::size_t size)
template<>
void | check_container_size< 4 > (std::size_t)
template<std::size_t N>
void | check_container_size_for_ext (std::size_t size)
template<>
void | check_container_size_for_ext< 4 > (std::size_t size)
template<std::size_t N>
std::size_t | add_ext_type_size (std::size_t size)
template<>
std::size_t | add_ext_type_size< 4 > (std::size_t size)
void | unpack_uint8 (uint8_t d, msgpack::object &o)
void | unpack_uint16 (uint16_t d, msgpack::object &o)
void | unpack_uint32 (uint32_t d, msgpack::object &o)
void | unpack_uint64 (uint64_t d, msgpack::object &o)
void | unpack_int8 (int8_t d, msgpack::object &o)
void | unpack_int16 (int16_t d, msgpack::object &o)
void | unpack_int32 (int32_t d, msgpack::object &o)
void | unpack_int64 (int64_t d, msgpack::object &o)
void | unpack_float (float d, msgpack::object &o)
void | unpack_double (double d, msgpack::object &o)
void | unpack_nil (msgpack::object &o)
void | unpack_true (msgpack::object &o)
void | unpack_false (msgpack::object &o)
void | unpack_array_item (msgpack::object &c, msgpack::object const &o)
void | unpack_map_item (msgpack::object &c, msgpack::object const &k, msgpack::object const &v)
void | unpack_str (unpack_user &u, const char *p, uint32_t l, msgpack::object &o)
void | unpack_bin (unpack_user &u, const char *p, uint32_t l, msgpack::object &o)
void | unpack_ext (unpack_user &u, const char *p, std::size_t l, msgpack::object &o)
void | init_count (void *buffer)
void | decr_count (void *buffer)
void | incr_count (void *buffer)
std::atomic< unsigned int > const & | get_count (void *buffer)
template<typename T >
msgpack::enable_if< sizeof(T)==sizeof(fix_tag)>::type | load (uint32_t &dst, const char *n)
template<typename T >
msgpack::enable_if< sizeof(T)==1 >::type | load (T &dst, const char *n)
template<typename T >
msgpack::enable_if< sizeof(T)==2 >::type | load (T &dst, const char *n)
template<typename T >
msgpack::enable_if< sizeof(T)==4 >::type | load (T &dst, const char *n)
template<typename T >
msgpack::enable_if< sizeof(T)==8 >::type | load (T &dst, const char *n)
parse_return | unpack_imp (const char *data, std::size_t len, std::size_t &off, msgpack::zone &result_zone, msgpack::object &result, bool &referenced, unpack_reference_func f=MSGPACK_NULLPTR, void *user_data=MSGPACK_NULLPTR, unpack_limit const &limit=unpack_limit())
template<std::size_t N>
void | check_ext_size (std::size_t)
template<>
void | check_ext_size< 4 > (std::size_t size)
template<typename Visitor >
parse_return | parse_imp (const char *data, size_t len, size_t &off, Visitor &v)
template<typename UnpackVisitor >
parse_return | parse_imp (const char *data, size_t len, size_t &off, UnpackVisitor &v)

## Variables

std::size_t const | packer_max_buffer_size = 9

## Function Documentation

## add_ext_type_size()

template<std::size_t N>

std::size_t msgpack::detail::add_ext_type_size | ( | std::size_t | size | ) |

inline

Referenced by msgpack::aligned_zone_size().

## add_ext_type_size< 4 >()

template<>

std::size_t msgpack::detail::add_ext_type_size< 4 > | ( | std::size_t | size | ) |

inline

References msgpack::type::size().

## check_container_size()

template<std::size_t N>

void msgpack::detail::check_container_size | ( | std::size_t | size | ) |

inline

References msgpack::container_size_overflow::container_size_overflow().

## check_container_size< 4 >()

template<>

void msgpack::detail::check_container_size< 4 > | ( | std::size_t |  | ) |

inline

## check_container_size_for_ext()

template<std::size_t N>

void msgpack::detail::check_container_size_for_ext | ( | std::size_t | size | ) |

inline

References msgpack::container_size_overflow::container_size_overflow().

## check_container_size_for_ext< 4 >()

template<>

void msgpack::detail::check_container_size_for_ext< 4 > | ( | std::size_t | size | ) |

inline

References msgpack::container_size_overflow::container_size_overflow(), and msgpack::type::size().

## check_ext_size()

template<std::size_t N>

void msgpack::detail::check_ext_size | ( | std::size_t |  | ) |

inline

References check_ext_size().

Referenced by check_ext_size(), and msgpack::detail::context< unpacker >::user().

## check_ext_size< 4 >()

template<>

void msgpack::detail::check_ext_size< 4 > | ( | std::size_t | size | ) |

inline

References msgpack::detail::context< VisitorHolder >::data(), msgpack::detail::context< VisitorHolder >::execute(), MSGPACK_NULLPTR, msgpack::PARSE_CONTINUE, msgpack::PARSE_PARSE_ERROR, and msgpack::type::size().

## decr_count()

void msgpack::detail::decr_count | ( | void * | buffer | ) |

inline

Referenced by msgpack::unpack_limit::depth(), msgpack::zone_push_finalizer::operator()(), msgpack::parser< unpacker, zone_push_finalizer >::reserve_buffer(), msgpack::unpacker::reserve_buffer(), msgpack::unpacker::reset_zone(), msgpack::unpacker::visitor(), msgpack::parser< unpacker, zone_push_finalizer >::~parser(), and msgpack::unpacker::~unpacker().

## get_count()

std::atomic< unsigned int > const & msgpack::detail::get_count | ( | void * | buffer | ) |

inline

Referenced by msgpack::unpack_limit::depth(), incr_count(), msgpack::parser< unpacker, zone_push_finalizer >::reserve_buffer(), and msgpack::unpacker::reserve_buffer().

## incr_count()

void msgpack::detail::incr_count | ( | void * | buffer | ) |

inline

References get_count().

Referenced by msgpack::unpack_limit::depth(), msgpack::unpacker::reset_zone(), and msgpack::unpacker::visitor().

## init_count()

void msgpack::detail::init_count | ( | void * | buffer | ) |

inline

Referenced by msgpack::unpack_limit::depth(), msgpack::parser< unpacker, zone_push_finalizer >::parser(), msgpack::parser< unpacker, zone_push_finalizer >::reserve_buffer(), msgpack::unpacker::reserve_buffer(), and msgpack::unpacker::unpacker().

## load() [1/5]

template<typename T >

msgpack::enable_if< sizeof(T)==sizeof(fix_tag)>::type msgpack::detail::load | ( | uint32_t & | dst,
|  | const char * | n
| ) |  |

inline

## load() [2/5]

template<typename T >

msgpack::enable_if< sizeof(T)==1 >::type msgpack::detail::load | ( | T & | dst,
|  | const char * | n
| ) |  |

inline

## load() [3/5]

template<typename T >

msgpack::enable_if< sizeof(T)==2 >::type msgpack::detail::load | ( | T & | dst,
|  | const char * | n
| ) |  |

inline

## load() [4/5]

template<typename T >

msgpack::enable_if< sizeof(T)==4 >::type msgpack::detail::load | ( | T & | dst,
|  | const char * | n
| ) |  |

inline

## load() [5/5]

template<typename T >

msgpack::enable_if< sizeof(T)==8 >::type msgpack::detail::load | ( | T & | dst,
|  | const char * | n
| ) |  |

inline

## parse_imp() [1/2]

template<typename UnpackVisitor >

parse_return msgpack::detail::parse_imp | ( | const char * | data,
|  | size_t | len,
|  | size_t & | off,
|  | UnpackVisitor & | v
| ) |  |

## parse_imp() [2/2]

template<typename Visitor >

parse_return msgpack::detail::parse_imp | ( | const char * | data,
|  | size_t | len,
|  | size_t & | off,
|  | Visitor & | v
| ) |  |

inline

References msgpack::detail::parse_helper< Visitor >::execute(), msgpack::PARSE_CONTINUE, msgpack::PARSE_EXTRA_BYTES, and msgpack::PARSE_SUCCESS.

Referenced by msgpack::parse(), and msgpack::unpack().

## unpack_array_item()

void msgpack::detail::unpack_array_item | ( | msgpack::object & | c,
|  | msgpack::object const & | o
| ) |  |

inline

References msgpack::object::union_type::array, msgpack::object_array::ptr, msgpack::object_array::size, and msgpack::object::via.

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::user().

## unpack_bin()

void msgpack::detail::unpack_bin | ( | unpack_user & | u,
|  | const char * | p,
|  | uint32_t | l,
|  | msgpack::object & | o
| ) |  |

inline

References msgpack::zone::allocate_align(), msgpack::type::BIN, msgpack::object::union_type::bin, msgpack::unpack_limit::bin(), msgpack::detail::unpack_user::limit(), MSGPACK_ZONE_ALIGNOF, msgpack::object_bin::ptr, msgpack::detail::unpack_user::reference_func(), msgpack::detail::unpack_user::set_referenced(), msgpack::object_bin::size, msgpack::object::type, msgpack::detail::unpack_user::user_data(), msgpack::object::via, and msgpack::detail::unpack_user::zone().

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::execute().

## unpack_double()

void msgpack::detail::unpack_double | ( | double | d,
|  | msgpack::object & | o
| ) |  |

inline

References msgpack::object::union_type::f64, msgpack::type::FLOAT64, msgpack::object::type, and msgpack::object::via.

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::execute().

## unpack_ext()

void msgpack::detail::unpack_ext | ( | unpack_user & | u,
|  | const char * | p,
|  | std::size_t | l,
|  | msgpack::object & | o
| ) |  |

inline

References msgpack::zone::allocate_align(), msgpack::type::EXT, msgpack::object::union_type::ext, msgpack::unpack_limit::ext(), msgpack::detail::unpack_user::limit(), MSGPACK_ZONE_ALIGNOF, msgpack::object_ext::ptr, msgpack::detail::unpack_user::reference_func(), msgpack::detail::unpack_user::set_referenced(), msgpack::object_ext::size, msgpack::object::type, msgpack::detail::unpack_user::user_data(), msgpack::object::via, and msgpack::detail::unpack_user::zone().

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::execute().

## unpack_false()

void msgpack::detail::unpack_false | ( | msgpack::object & | o | ) |

inline

References msgpack::type::BOOLEAN, msgpack::object::union_type::boolean, msgpack::object::type, and msgpack::object::via.

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::execute().

## unpack_float()

void msgpack::detail::unpack_float | ( | float | d,
|  | msgpack::object & | o
| ) |  |

inline

References msgpack::object::union_type::f64, msgpack::type::FLOAT32, msgpack::object::type, and msgpack::object::via.

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::execute().

## unpack_imp()

parse_return msgpack::detail::unpack_imp | ( | const char * | data,
|  | std::size_t | len,
|  | std::size_t & | off,
|  | msgpack::zone & | result_zone,
|  | msgpack::object & | result,
|  | bool & | referenced,
|  | unpack_reference_func | f = `MSGPACK_NULLPTR`,
|  | void * | user_data = `MSGPACK_NULLPTR`,
|  | unpack_limit const & | limit = `unpack_limit()`
| ) |  |

inline

References msgpack::detail::context< VisitorHolder >::data(), msgpack::detail::context< VisitorHolder >::execute(), msgpack::detail::context< VisitorHolder >::init(), msgpack::PARSE_CONTINUE, msgpack::PARSE_EXTRA_BYTES, msgpack::PARSE_PARSE_ERROR, msgpack::PARSE_SUCCESS, msgpack::detail::unpack_user::referenced(), msgpack::detail::unpack_user::set_referenced(), msgpack::detail::unpack_user::set_zone(), and msgpack::detail::context< VisitorHolder >::user().

Referenced by msgpack::unpack(), and msgpack::unpacker::visitor().

## unpack_int16()

void msgpack::detail::unpack_int16 | ( | int16_t | d,
|  | msgpack::object & | o
| ) |  |

inline

References msgpack::object::union_type::i64, msgpack::type::NEGATIVE_INTEGER, msgpack::type::POSITIVE_INTEGER, msgpack::object::type, msgpack::object::union_type::u64, and msgpack::object::via.

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::execute().

## unpack_int32()

void msgpack::detail::unpack_int32 | ( | int32_t | d,
|  | msgpack::object & | o
| ) |  |

inline

References msgpack::object::union_type::i64, msgpack::type::NEGATIVE_INTEGER, msgpack::type::POSITIVE_INTEGER, msgpack::object::type, msgpack::object::union_type::u64, and msgpack::object::via.

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::execute().

## unpack_int64()

void msgpack::detail::unpack_int64 | ( | int64_t | d,
|  | msgpack::object & | o
| ) |  |

inline

References msgpack::object::union_type::i64, msgpack::type::NEGATIVE_INTEGER, msgpack::type::POSITIVE_INTEGER, msgpack::object::type, msgpack::object::union_type::u64, and msgpack::object::via.

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::execute().

## unpack_int8()

void msgpack::detail::unpack_int8 | ( | int8_t | d,
|  | msgpack::object & | o
| ) |  |

inline

References msgpack::object::union_type::i64, msgpack::type::NEGATIVE_INTEGER, msgpack::type::POSITIVE_INTEGER, msgpack::object::type, msgpack::object::union_type::u64, and msgpack::object::via.

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::execute().

## unpack_map_item()

void msgpack::detail::unpack_map_item | ( | msgpack::object & | c,
|  | msgpack::object const & | k,
|  | msgpack::object const & | v
| ) |  |

inline

References msgpack::object_kv::key, msgpack::object::union_type::map, msgpack::object_map::ptr, msgpack::object_map::size, msgpack::object_kv::val, and msgpack::object::via.

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::user().

## unpack_nil()

void msgpack::detail::unpack_nil | ( | msgpack::object & | o | ) |

inline

References msgpack::type::NIL, and msgpack::object::type.

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::execute().

## unpack_str()

void msgpack::detail::unpack_str | ( | unpack_user & | u,
|  | const char * | p,
|  | uint32_t | l,
|  | msgpack::object & | o
| ) |  |

inline

References msgpack::zone::allocate_align(), msgpack::detail::unpack_user::limit(), MSGPACK_ZONE_ALIGNOF, msgpack::object_str::ptr, msgpack::detail::unpack_user::reference_func(), msgpack::detail::unpack_user::set_referenced(), msgpack::object_str::size, msgpack::type::STR, msgpack::object::union_type::str, msgpack::unpack_limit::str(), msgpack::object::type, msgpack::detail::unpack_user::user_data(), msgpack::object::via, and msgpack::detail::unpack_user::zone().

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::execute().

## unpack_true()

void msgpack::detail::unpack_true | ( | msgpack::object & | o | ) |

inline

References msgpack::type::BOOLEAN, msgpack::object::union_type::boolean, msgpack::object::type, and msgpack::object::via.

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::execute().

## unpack_uint16()

void msgpack::detail::unpack_uint16 | ( | uint16_t | d,
|  | msgpack::object & | o
| ) |  |

inline

References msgpack::type::POSITIVE_INTEGER, msgpack::object::type, msgpack::object::union_type::u64, and msgpack::object::via.

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::execute().

## unpack_uint32()

void msgpack::detail::unpack_uint32 | ( | uint32_t | d,
|  | msgpack::object & | o
| ) |  |

inline

References msgpack::type::POSITIVE_INTEGER, msgpack::object::type, msgpack::object::union_type::u64, and msgpack::object::via.

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::execute().

## unpack_uint64()

void msgpack::detail::unpack_uint64 | ( | uint64_t | d,
|  | msgpack::object & | o
| ) |  |

inline

References msgpack::type::POSITIVE_INTEGER, msgpack::object::type, msgpack::object::union_type::u64, and msgpack::object::via.

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::execute().

## unpack_uint8()

void msgpack::detail::unpack_uint8 | ( | uint8_t | d,
|  | msgpack::object & | o
| ) |  |

inline

References msgpack::type::POSITIVE_INTEGER, msgpack::object::type, msgpack::object::union_type::u64, and msgpack::object::via.

Referenced by msgpack::unpack_limit::depth(), and msgpack::detail::context< unpacker >::execute().

## Variable Documentation

## packer_max_buffer_size

std::size_t const msgpack::detail::packer_max_buffer_size = 9