10#ifndef MSGPACK_V1_TYPE_DEQUE_HPP
11#define MSGPACK_V1_TYPE_DEQUE_HPP
28#if !defined(MSGPACK_USE_CPP03)
30template <
typename T,
typename Alloc>
31struct as<std::
deque<T, Alloc>,
typename std::enable_if<msgpack::has_as<T>::value>::type> {
34 std::deque<T, Alloc>
v;
35 if (
o.via.array.size > 0) {
39 v.push_back(
p->as<
T>());
49template <
typename T,
typename Alloc>
53 v.resize(
o.via.array.size);
56 typename std::deque<T, Alloc>::iterator
it =
v.begin();
64template <
typename T,
typename Alloc>
66 template <
typename Stream>
70 for(
typename std::deque<T, Alloc>::const_iterator
it(
v.begin()),
it_end(
v.end());
78template <
typename T,
typename Alloc>
81 o.type = msgpack::type::ARRAY;
90 o.via.array.size = size;
91 typename std::deque<T, Alloc>::const_iterator
it(
v.begin());
The class template that supports continuous packing.
Definition pack.hpp:33
Definition object_fwd.hpp:231
Definition adaptor_base.hpp:15
uint32_t checked_get_container_size(T size)
Definition check_container_size.hpp:55
std::deque< T, Alloc > operator()(const msgpack::object &o) const
Definition deque.hpp:32
Definition object_fwd_decl.hpp:61
msgpack::object const & operator()(msgpack::object const &o, std::deque< T, Alloc > &v) const
Definition deque.hpp:51
Definition adaptor_base.hpp:27
void operator()(msgpack::object::with_zone &o, const std::deque< T, Alloc > &v) const
Definition deque.hpp:80
Definition adaptor_base.hpp:43
msgpack::packer< Stream > & operator()(msgpack::packer< Stream > &o, const std::deque< T, Alloc > &v) const
Definition deque.hpp:67
Definition adaptor_base.hpp:32
Object class that corresponding to MessagePack format object.
Definition object_fwd.hpp:75
#define MSGPACK_NULLPTR
Definition cpp_config_decl.hpp:85
#define MSGPACK_ZONE_ALIGNOF(type)
Definition cpp03_zone_decl.hpp:30
#define MSGPACK_API_VERSION_NAMESPACE(ns)
Definition versioning.hpp:66