Mercurial > hg > vamp-build-and-test
comparison DEPENDENCIES/generic/include/boost/interprocess/interprocess_fwd.hpp @ 16:2665513ce2d3
Add boost headers
author | Chris Cannam |
---|---|
date | Tue, 05 Aug 2014 11:11:38 +0100 |
parents | |
children | c530137014c0 |
comparison
equal
deleted
inserted
replaced
15:663ca0da4350 | 16:2665513ce2d3 |
---|---|
1 ////////////////////////////////////////////////////////////////////////////// | |
2 // | |
3 // (C) Copyright Ion Gaztanaga 2005-2012. Distributed under the Boost | |
4 // Software License, Version 1.0. (See accompanying file | |
5 // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt) | |
6 // | |
7 // See http://www.boost.org/libs/interprocess for documentation. | |
8 // | |
9 ////////////////////////////////////////////////////////////////////////////// | |
10 | |
11 #ifndef BOOST_INTERPROCESS_FWD_HPP | |
12 #define BOOST_INTERPROCESS_FWD_HPP | |
13 | |
14 #if defined (_MSC_VER) && (_MSC_VER >= 1200) | |
15 # pragma once | |
16 #endif | |
17 | |
18 #include <boost/interprocess/detail/config_begin.hpp> | |
19 #include <boost/interprocess/detail/workaround.hpp> | |
20 | |
21 #include <cstddef> | |
22 | |
23 ////////////////////////////////////////////////////////////////////////////// | |
24 // Standard predeclarations | |
25 ////////////////////////////////////////////////////////////////////////////// | |
26 | |
27 /// @cond | |
28 | |
29 namespace boost{ | |
30 namespace intrusive{ | |
31 }} | |
32 | |
33 namespace boost{ | |
34 namespace interprocess{ | |
35 namespace bi = boost::intrusive; | |
36 }} | |
37 | |
38 #include <utility> | |
39 #include <memory> | |
40 #include <functional> | |
41 #include <iosfwd> | |
42 #include <string> | |
43 | |
44 /// @endcond | |
45 | |
46 namespace boost { namespace interprocess { | |
47 | |
48 ////////////////////////////////////////////////////////////////////////////// | |
49 // permissions | |
50 ////////////////////////////////////////////////////////////////////////////// | |
51 | |
52 class permissions; | |
53 | |
54 ////////////////////////////////////////////////////////////////////////////// | |
55 // shared_memory | |
56 ////////////////////////////////////////////////////////////////////////////// | |
57 | |
58 class shared_memory_object; | |
59 | |
60 #if defined (BOOST_INTERPROCESS_WINDOWS) || defined(BOOST_INTERPROCESS_DOXYGEN_INVOKED) | |
61 class windows_shared_memory; | |
62 #endif //#if defined (BOOST_INTERPROCESS_WINDOWS) | |
63 | |
64 ////////////////////////////////////////////////////////////////////////////// | |
65 // mapped file/mapped region/mapped_file | |
66 ////////////////////////////////////////////////////////////////////////////// | |
67 | |
68 class file_mapping; | |
69 class mapped_region; | |
70 class mapped_file; | |
71 | |
72 ////////////////////////////////////////////////////////////////////////////// | |
73 // Mutexes | |
74 ////////////////////////////////////////////////////////////////////////////// | |
75 | |
76 class null_mutex; | |
77 | |
78 class interprocess_mutex; | |
79 class interprocess_recursive_mutex; | |
80 | |
81 class named_mutex; | |
82 class named_recursive_mutex; | |
83 | |
84 class interprocess_semaphore; | |
85 class named_semaphore; | |
86 | |
87 ////////////////////////////////////////////////////////////////////////////// | |
88 // Mutex families | |
89 ////////////////////////////////////////////////////////////////////////////// | |
90 | |
91 struct mutex_family; | |
92 struct null_mutex_family; | |
93 | |
94 ////////////////////////////////////////////////////////////////////////////// | |
95 // Other synchronization classes | |
96 ////////////////////////////////////////////////////////////////////////////// | |
97 | |
98 class barrier; | |
99 class interprocess_sharable_mutex; | |
100 class interprocess_condition; | |
101 | |
102 ////////////////////////////////////////////////////////////////////////////// | |
103 // Locks | |
104 ////////////////////////////////////////////////////////////////////////////// | |
105 | |
106 template <class Mutex> | |
107 class scoped_lock; | |
108 | |
109 template <class SharableMutex> | |
110 class sharable_lock; | |
111 | |
112 template <class UpgradableMutex> | |
113 class upgradable_lock; | |
114 | |
115 ////////////////////////////////////////////////////////////////////////////// | |
116 // STL compatible allocators | |
117 ////////////////////////////////////////////////////////////////////////////// | |
118 | |
119 template<class T, class SegmentManager> | |
120 class allocator; | |
121 | |
122 template<class T, class SegmentManager, std::size_t NodesPerBlock = 64> | |
123 class node_allocator; | |
124 | |
125 template<class T, class SegmentManager, std::size_t NodesPerBlock = 64> | |
126 class private_node_allocator; | |
127 | |
128 template<class T, class SegmentManager, std::size_t NodesPerBlock = 64> | |
129 class cached_node_allocator; | |
130 | |
131 template<class T, class SegmentManager, std::size_t NodesPerBlock = 64, std::size_t MaxFreeBlocks = 2 | |
132 , unsigned char OverheadPercent = 5 | |
133 > | |
134 class adaptive_pool; | |
135 | |
136 template<class T, class SegmentManager, std::size_t NodesPerBlock = 64, std::size_t MaxFreeBlocks = 2 | |
137 , unsigned char OverheadPercent = 5 | |
138 > | |
139 class private_adaptive_pool; | |
140 | |
141 template<class T, class SegmentManager, std::size_t NodesPerBlock = 64, std::size_t MaxFreeBlocks = 2 | |
142 , unsigned char OverheadPercent = 5 | |
143 > | |
144 class cached_adaptive_pool; | |
145 | |
146 | |
147 ////////////////////////////////////////////////////////////////////////////// | |
148 // offset_ptr | |
149 ////////////////////////////////////////////////////////////////////////////// | |
150 | |
151 static const std::size_t offset_type_alignment = 0; | |
152 | |
153 template <class T, class DifferenceType = std::ptrdiff_t, class OffsetType = std::size_t, std::size_t Alignment = offset_type_alignment> | |
154 class offset_ptr; | |
155 | |
156 ////////////////////////////////////////////////////////////////////////////// | |
157 // Memory allocation algorithms | |
158 ////////////////////////////////////////////////////////////////////////////// | |
159 | |
160 //Single segment memory allocation algorithms | |
161 template<class MutexFamily, class VoidMutex = offset_ptr<void> > | |
162 class simple_seq_fit; | |
163 | |
164 template<class MutexFamily, class VoidMutex = offset_ptr<void>, std::size_t MemAlignment = 0> | |
165 class rbtree_best_fit; | |
166 | |
167 ////////////////////////////////////////////////////////////////////////////// | |
168 // Index Types | |
169 ////////////////////////////////////////////////////////////////////////////// | |
170 | |
171 template<class IndexConfig> class flat_map_index; | |
172 template<class IndexConfig> class iset_index; | |
173 template<class IndexConfig> class iunordered_set_index; | |
174 template<class IndexConfig> class map_index; | |
175 template<class IndexConfig> class null_index; | |
176 template<class IndexConfig> class unordered_map_index; | |
177 | |
178 ////////////////////////////////////////////////////////////////////////////// | |
179 // Segment manager | |
180 ////////////////////////////////////////////////////////////////////////////// | |
181 | |
182 template <class CharType | |
183 ,class MemoryAlgorithm | |
184 ,template<class IndexConfig> class IndexType> | |
185 class segment_manager; | |
186 | |
187 ////////////////////////////////////////////////////////////////////////////// | |
188 // External buffer managed memory classes | |
189 ////////////////////////////////////////////////////////////////////////////// | |
190 | |
191 template <class CharType | |
192 ,class MemoryAlgorithm | |
193 ,template<class IndexConfig> class IndexType> | |
194 class basic_managed_external_buffer; | |
195 | |
196 typedef basic_managed_external_buffer | |
197 <char | |
198 ,rbtree_best_fit<null_mutex_family> | |
199 ,iset_index> | |
200 managed_external_buffer; | |
201 | |
202 typedef basic_managed_external_buffer | |
203 <wchar_t | |
204 ,rbtree_best_fit<null_mutex_family> | |
205 ,iset_index> | |
206 wmanaged_external_buffer; | |
207 | |
208 ////////////////////////////////////////////////////////////////////////////// | |
209 // managed memory classes | |
210 ////////////////////////////////////////////////////////////////////////////// | |
211 | |
212 template <class CharType | |
213 ,class MemoryAlgorithm | |
214 ,template<class IndexConfig> class IndexType> | |
215 class basic_managed_shared_memory; | |
216 | |
217 typedef basic_managed_shared_memory | |
218 <char | |
219 ,rbtree_best_fit<mutex_family> | |
220 ,iset_index> | |
221 managed_shared_memory; | |
222 | |
223 typedef basic_managed_shared_memory | |
224 <wchar_t | |
225 ,rbtree_best_fit<mutex_family> | |
226 ,iset_index> | |
227 wmanaged_shared_memory; | |
228 | |
229 | |
230 ////////////////////////////////////////////////////////////////////////////// | |
231 // Windows shared memory managed memory classes | |
232 ////////////////////////////////////////////////////////////////////////////// | |
233 | |
234 #if defined (BOOST_INTERPROCESS_WINDOWS) || defined(BOOST_INTERPROCESS_DOXYGEN_INVOKED) | |
235 | |
236 template <class CharType | |
237 ,class MemoryAlgorithm | |
238 ,template<class IndexConfig> class IndexType> | |
239 class basic_managed_windows_shared_memory; | |
240 | |
241 typedef basic_managed_windows_shared_memory | |
242 <char | |
243 ,rbtree_best_fit<mutex_family> | |
244 ,iset_index> | |
245 managed_windows_shared_memory; | |
246 | |
247 typedef basic_managed_windows_shared_memory | |
248 <wchar_t | |
249 ,rbtree_best_fit<mutex_family> | |
250 ,iset_index> | |
251 wmanaged_windows_shared_memory; | |
252 | |
253 #endif //#if defined (BOOST_INTERPROCESS_WINDOWS) | |
254 | |
255 #if defined(BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS) || defined(BOOST_INTERPROCESS_DOXYGEN_INVOKED) | |
256 | |
257 template <class CharType | |
258 ,class MemoryAlgorithm | |
259 ,template<class IndexConfig> class IndexType> | |
260 class basic_managed_xsi_shared_memory; | |
261 | |
262 typedef basic_managed_xsi_shared_memory | |
263 <char | |
264 ,rbtree_best_fit<mutex_family> | |
265 ,iset_index> | |
266 managed_xsi_shared_memory; | |
267 | |
268 typedef basic_managed_xsi_shared_memory | |
269 <wchar_t | |
270 ,rbtree_best_fit<mutex_family> | |
271 ,iset_index> | |
272 wmanaged_xsi_shared_memory; | |
273 | |
274 #endif //#if defined(BOOST_INTERPROCESS_XSI_SHARED_MEMORY_OBJECTS) | |
275 | |
276 ////////////////////////////////////////////////////////////////////////////// | |
277 // Fixed address shared memory | |
278 ////////////////////////////////////////////////////////////////////////////// | |
279 | |
280 typedef basic_managed_shared_memory | |
281 <char | |
282 ,rbtree_best_fit<mutex_family, void*> | |
283 ,iset_index> | |
284 fixed_managed_shared_memory; | |
285 | |
286 typedef basic_managed_shared_memory | |
287 <wchar_t | |
288 ,rbtree_best_fit<mutex_family, void*> | |
289 ,iset_index> | |
290 wfixed_managed_shared_memory; | |
291 | |
292 ////////////////////////////////////////////////////////////////////////////// | |
293 // Heap memory managed memory classes | |
294 ////////////////////////////////////////////////////////////////////////////// | |
295 | |
296 template | |
297 <class CharType | |
298 ,class MemoryAlgorithm | |
299 ,template<class IndexConfig> class IndexType> | |
300 class basic_managed_heap_memory; | |
301 | |
302 typedef basic_managed_heap_memory | |
303 <char | |
304 ,rbtree_best_fit<null_mutex_family> | |
305 ,iset_index> | |
306 managed_heap_memory; | |
307 | |
308 typedef basic_managed_heap_memory | |
309 <wchar_t | |
310 ,rbtree_best_fit<null_mutex_family> | |
311 ,iset_index> | |
312 wmanaged_heap_memory; | |
313 | |
314 ////////////////////////////////////////////////////////////////////////////// | |
315 // Mapped file managed memory classes | |
316 ////////////////////////////////////////////////////////////////////////////// | |
317 | |
318 template | |
319 <class CharType | |
320 ,class MemoryAlgorithm | |
321 ,template<class IndexConfig> class IndexType> | |
322 class basic_managed_mapped_file; | |
323 | |
324 typedef basic_managed_mapped_file | |
325 <char | |
326 ,rbtree_best_fit<mutex_family> | |
327 ,iset_index> | |
328 managed_mapped_file; | |
329 | |
330 typedef basic_managed_mapped_file | |
331 <wchar_t | |
332 ,rbtree_best_fit<mutex_family> | |
333 ,iset_index> | |
334 wmanaged_mapped_file; | |
335 | |
336 ////////////////////////////////////////////////////////////////////////////// | |
337 // Exceptions | |
338 ////////////////////////////////////////////////////////////////////////////// | |
339 | |
340 class interprocess_exception; | |
341 class lock_exception; | |
342 class bad_alloc; | |
343 | |
344 ////////////////////////////////////////////////////////////////////////////// | |
345 // Bufferstream | |
346 ////////////////////////////////////////////////////////////////////////////// | |
347 | |
348 //bufferstream | |
349 template <class CharT | |
350 ,class CharTraits = std::char_traits<CharT> > | |
351 class basic_bufferbuf; | |
352 | |
353 template <class CharT | |
354 ,class CharTraits = std::char_traits<CharT> > | |
355 class basic_ibufferstream; | |
356 | |
357 template <class CharT | |
358 ,class CharTraits = std::char_traits<CharT> > | |
359 class basic_obufferstream; | |
360 | |
361 template <class CharT | |
362 ,class CharTraits = std::char_traits<CharT> > | |
363 class basic_bufferstream; | |
364 | |
365 ////////////////////////////////////////////////////////////////////////////// | |
366 // Vectorstream | |
367 ////////////////////////////////////////////////////////////////////////////// | |
368 | |
369 template <class CharVector | |
370 ,class CharTraits = std::char_traits<typename CharVector::value_type> > | |
371 class basic_vectorbuf; | |
372 | |
373 template <class CharVector | |
374 ,class CharTraits = std::char_traits<typename CharVector::value_type> > | |
375 class basic_ivectorstream; | |
376 | |
377 template <class CharVector | |
378 ,class CharTraits = std::char_traits<typename CharVector::value_type> > | |
379 class basic_ovectorstream; | |
380 | |
381 template <class CharVector | |
382 ,class CharTraits = std::char_traits<typename CharVector::value_type> > | |
383 class basic_vectorstream; | |
384 | |
385 ////////////////////////////////////////////////////////////////////////////// | |
386 // Smart pointers | |
387 ////////////////////////////////////////////////////////////////////////////// | |
388 | |
389 template<class T, class Deleter> | |
390 class scoped_ptr; | |
391 | |
392 template<class T, class VoidPointer> | |
393 class intrusive_ptr; | |
394 | |
395 template<class T, class VoidAllocator, class Deleter> | |
396 class shared_ptr; | |
397 | |
398 template<class T, class VoidAllocator, class Deleter> | |
399 class weak_ptr; | |
400 | |
401 ////////////////////////////////////////////////////////////////////////////// | |
402 // IPC | |
403 ////////////////////////////////////////////////////////////////////////////// | |
404 | |
405 template<class VoidPointer> | |
406 class message_queue_t; | |
407 | |
408 typedef message_queue_t<offset_ptr<void> > message_queue; | |
409 | |
410 }} //namespace boost { namespace interprocess { | |
411 | |
412 ////////////////////////////////////////////////////////////////////////////// | |
413 // CONTAINERS | |
414 ////////////////////////////////////////////////////////////////////////////// | |
415 | |
416 #include <boost/interprocess/detail/config_end.hpp> | |
417 | |
418 #endif //#ifndef BOOST_INTERPROCESS_FWD_HPP |