MessagePack for C++
Loading...
Searching...
No Matches
adaptor_base_decl.hpp
Go to the documentation of this file.
1//
2// MessagePack for C++ static resolution routine
3//
4// Copyright (C) 2016 KONDO Takatoshi
5//
6// Distributed under the Boost Software License, Version 1.0.
7// (See accompanying file LICENSE_1_0.txt or copy at
8// http://www.boost.org/LICENSE_1_0.txt)
9//
10#ifndef MSGPACK_V1_ADAPTOR_BASE_DECL_HPP
11#define MSGPACK_V1_ADAPTOR_BASE_DECL_HPP
12
15#include "msgpack/pack.hpp"
16
17namespace msgpack {
18
22
23template <typename Stream>
24class packer;
25
26namespace adaptor {
27
28// Adaptor functors
29
30template <typename T, typename Enabler = void>
31struct convert;
32
33template <typename T, typename Enabler = void>
34struct pack;
35
36template <typename T, typename Enabler = void>
37struct object;
38
39template <typename T, typename Enabler = void>
40struct object_with_zone;
41
42} // namespace adaptor
43
44// operators
45
46template <typename T>
47typename msgpack::enable_if<
48 !is_array<T>::value,
49 msgpack::object const&
50>::type
51operator>> (msgpack::object const& o, T& v);
52template <typename T, std::size_t N>
53msgpack::object const& operator>> (msgpack::object const& o, T(&v)[N]);
54
55template <typename Stream, typename T>
56typename msgpack::enable_if<
57 !is_array<T>::value,
59>::type
60operator<< (msgpack::packer<Stream>& o, T const& v);
61template <typename Stream, typename T, std::size_t N>
62msgpack::packer<Stream>& operator<< (msgpack::packer<Stream>& o, const T(&v)[N]);
63
64template <typename T>
65typename msgpack::enable_if<
66 !is_array<T>::value
67>::type
68operator<< (msgpack::object& o, T const& v);
69template <typename T, std::size_t N>
70void operator<< (msgpack::object& o, const T(&v)[N]);
71
72template <typename T>
73typename msgpack::enable_if<
74 !is_array<T>::value
75>::type
76operator<< (msgpack::object::with_zone& o, T const& v);
77template <typename T, std::size_t N>
78void operator<< (msgpack::object::with_zone& o, const T(&v)[N]);
79
81} // MSGPACK_API_VERSION_NAMESPACE(v1)
83
84} // namespace msgpack
85
86#endif // MSGPACK_V1_ADAPTOR_BASE_DECL_HPP
The class template that supports continuous packing.
Definition pack.hpp:33
Definition adaptor_base.hpp:15
void pack(msgpack::packer< Stream > &o, const T &v)
Definition object.hpp:1185
void convert(T &v, msgpack::object const &o)
Definition object.hpp:1178
Definition object.hpp:35
Object class that corresponding to MessagePack format object.
Definition object_fwd.hpp:75
#define MSGPACK_API_VERSION_NAMESPACE(ns)
Definition versioning.hpp:66