28#ifndef INCLUDED_MDDS_MULTI_TYPE_VECTOR_DIR_MACRO_HPP
29#define INCLUDED_MDDS_MULTI_TYPE_VECTOR_DIR_MACRO_HPP
44#define MDDS_MTV_DEFINE_ELEMENT_CALLBACKS(type, type_id, empty_value, block_type) \
46 inline mdds::mtv::element_t mdds_mtv_get_element_type(const type&) \
51 inline void mdds_mtv_get_empty_value(type& val) \
56 inline void mdds_mtv_set_value(mdds::mtv::base_element_block& block, size_t pos, const type& val) \
58 block_type::set_value(block, pos, val); \
61 inline void mdds_mtv_get_value(const mdds::mtv::base_element_block& block, size_t pos, type& val) \
63 block_type::get_value(block, pos, val); \
66 template<typename _Iter> \
67 void mdds_mtv_set_values( \
68 mdds::mtv::base_element_block& block, size_t pos, const type&, const _Iter& it_begin, const _Iter& it_end) \
70 block_type::set_values(block, pos, it_begin, it_end); \
73 inline void mdds_mtv_append_value(mdds::mtv::base_element_block& block, const type& val) \
75 block_type::append_value(block, val); \
78 inline void mdds_mtv_prepend_value(mdds::mtv::base_element_block& block, const type& val) \
80 block_type::prepend_value(block, val); \
83 template<typename _Iter> \
84 void mdds_mtv_prepend_values( \
85 mdds::mtv::base_element_block& block, const type&, const _Iter& it_begin, const _Iter& it_end) \
87 block_type::prepend_values(block, it_begin, it_end); \
90 template<typename _Iter> \
91 void mdds_mtv_append_values( \
92 mdds::mtv::base_element_block& block, const type&, const _Iter& it_begin, const _Iter& it_end) \
94 block_type::append_values(block, it_begin, it_end); \
97 template<typename _Iter> \
98 void mdds_mtv_assign_values( \
99 mdds::mtv::base_element_block& dest, const type&, const _Iter& it_begin, const _Iter& it_end) \
101 block_type::assign_values(dest, it_begin, it_end); \
104 template<typename _Iter> \
105 void mdds_mtv_insert_values( \
106 mdds::mtv::base_element_block& block, size_t pos, const type&, const _Iter& it_begin, const _Iter& it_end) \
108 block_type::insert_values(block, pos, it_begin, it_end); \
111 inline mdds::mtv::base_element_block* mdds_mtv_create_new_block(size_t init_size, const type& val) \
113 return block_type::create_block_with_value(init_size, val); \
116 template<typename _Iter> \
117 mdds::mtv::base_element_block* mdds_mtv_create_new_block(const type&, const _Iter& it_begin, const _Iter& it_end) \
119 return block_type::create_block_with_values(it_begin, it_end); \
129#define MDDS_MTV_DEFINE_ELEMENT_CALLBACKS_PTR(type, type_id, empty_value, block_type) \
131 inline mdds::mtv::element_t mdds_mtv_get_element_type(const type*) \
136 inline void mdds_mtv_get_empty_value(type*& val) \
141 inline void mdds_mtv_set_value(mdds::mtv::base_element_block& block, size_t pos, type* val) \
143 block_type::set_value(block, pos, val); \
146 inline void mdds_mtv_get_value(const mdds::mtv::base_element_block& block, size_t pos, type*& val) \
148 block_type::get_value(block, pos, val); \
151 template<typename _Iter> \
152 void mdds_mtv_set_values( \
153 mdds::mtv::base_element_block& block, size_t pos, const type*, const _Iter& it_begin, const _Iter& it_end) \
155 block_type::set_values(block, pos, it_begin, it_end); \
158 inline void mdds_mtv_append_value(mdds::mtv::base_element_block& block, type* val) \
160 block_type::append_value(block, val); \
163 inline void mdds_mtv_prepend_value(mdds::mtv::base_element_block& block, type* val) \
165 block_type::prepend_value(block, val); \
168 template<typename _Iter> \
169 void mdds_mtv_prepend_values( \
170 mdds::mtv::base_element_block& block, const type*, const _Iter& it_begin, const _Iter& it_end) \
172 block_type::prepend_values(block, it_begin, it_end); \
175 template<typename _Iter> \
176 void mdds_mtv_append_values( \
177 mdds::mtv::base_element_block& block, const type*, const _Iter& it_begin, const _Iter& it_end) \
179 block_type::append_values(block, it_begin, it_end); \
182 template<typename _Iter> \
183 void mdds_mtv_assign_values( \
184 mdds::mtv::base_element_block& dest, const type*, const _Iter& it_begin, const _Iter& it_end) \
186 block_type::assign_values(dest, it_begin, it_end); \
189 template<typename _Iter> \
190 void mdds_mtv_insert_values( \
191 mdds::mtv::base_element_block& block, size_t pos, const type*, const _Iter& it_begin, const _Iter& it_end) \
193 block_type::insert_values(block, pos, it_begin, it_end); \
196 inline mdds::mtv::base_element_block* mdds_mtv_create_new_block(size_t init_size, type* val) \
198 return block_type::create_block_with_value(init_size, val); \
201 template<typename _Iter> \
202 mdds::mtv::base_element_block* mdds_mtv_create_new_block(const type*, const _Iter& it_begin, const _Iter& it_end) \
204 return block_type::create_block_with_values(it_begin, it_end); \