ReactOS 0.4.16-dev-92-g0c2cdca
_set.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2005
3 * Francois Dumont
4 *
5 * This material is provided "as is", with absolutely no warranty expressed
6 * or implied. Any use is at your own risk.
7 *
8 * Permission to use or copy this software for any purpose is hereby granted
9 * without fee, provided the above notices are retained on all copies.
10 * Permission to modify the code and to distribute modified code is granted,
11 * provided the above notices are retained, and a notice that the code was
12 * modified is included with the above copyright notice.
13 */
14
15/* NOTE: This is an internal header file, included by other STL headers.
16 * You should not attempt to use it directly.
17 */
18
19#ifndef _STLP_PTR_SPECIALIZED_SET_H
20#define _STLP_PTR_SPECIALIZED_SET_H
21
22#ifndef _STLP_POINTERS_SPEC_TOOLS_H
23# include <stl/pointers/_tools.h>
24#endif
25
27
28#if defined (__BORLANDC__) || defined (__DMC__)
29# define typename
30#endif
31
32//Specific iterator traits creation
33_STLP_CREATE_ITERATOR_TRAITS(SetTraitsT, Const_traits)
34
35#if defined (_STLP_USE_TEMPLATE_EXPORT) && !defined (_STLP_USE_MSVC6_MEM_T_BUG_WORKAROUND)
37
39
40typedef _Rb_tree_node<void*> _Node;
43# if defined (_STLP_DEBUG)
45# define _Rb_tree _STLP_NON_DBG_NAME(Rb_tree)
47 _SetTraitsT<void*>, allocator<void*> >;
48# undef _Rb_tree
49# endif
51 _SetTraitsT<void*>, allocator<void*> >;
53#endif
54
55template <class _Key, _STLP_DFL_TMPL_PARAM(_Compare, less<_Key>),
56 _STLP_DFL_TMPL_PARAM(_Alloc, allocator<_Key>) >
57class set
58#if defined (_STLP_USE_PARTIAL_SPEC_WORKAROUND)
59 : public __stlport_class<set<_Key, _Compare, _Alloc> >
60#endif
61{
62#if !defined (__BORLANDC__)
66#else
69#endif
72
74public:
75 typedef _Key key_type;
76 typedef _Key value_type;
77 typedef _Compare key_compare;
78 typedef _Compare value_compare;
79
80protected:
81 //Specific iterator traits creation
82 typedef _STLP_PRIV _SetTraitsT<value_type> _SetTraits;
86
87 typedef _STLP_PRIV _SetTraitsT<_KeyStorageType> _SetStorageTraits;
88
89public:
90 //dums: need the following public for the __move_traits framework
94
95private:
96 typedef typename _Rep_type::iterator base_iterator;
97 typedef typename _Rep_type::const_iterator const_base_iterator;
98
99public:
100 typedef typename _Priv_Rep_type::pointer pointer;
101 typedef typename _Priv_Rep_type::const_pointer const_pointer;
102 typedef typename _Priv_Rep_type::reference reference;
103 typedef typename _Priv_Rep_type::const_reference const_reference;
104 typedef typename _Priv_Rep_type::iterator iterator;
105 typedef typename _Priv_Rep_type::const_iterator const_iterator;
106 typedef typename _Priv_Rep_type::reverse_iterator reverse_iterator;
107 typedef typename _Priv_Rep_type::const_reverse_iterator const_reverse_iterator;
108 typedef typename _Priv_Rep_type::size_type size_type;
109 typedef typename _Priv_Rep_type::difference_type difference_type;
110 typedef typename _Priv_Rep_type::allocator_type allocator_type;
111
112private:
113 _Rep_type _M_t; // red-black tree representing set
115
116#if defined (_STLP_DEBUG)
118 { return iterator(__ite._Owner(), __ite._M_iterator._M_node); }
120 { return base_iterator(__ite._Owner(), __ite._M_iterator._M_node); }
121#else
123 { return iterator(__ite._M_node); }
125 { return base_iterator(__ite._M_node); }
126#endif
127
128public:
130 explicit set(const _Compare& __comp,
131 const allocator_type& __a = allocator_type())
133
134#if defined (_STLP_MEMBER_TEMPLATES)
135 template <class _InputIterator>
136 set(_InputIterator __first, _InputIterator __last)
137 : _M_t(_Compare(), _StorageTypeAlloc()) {
138# if defined (_STLP_USE_ITERATOR_WRAPPER)
139 _M_t.insert_unique(_STLP_TYPENAME _STLP_PRIV _IteWrapper<_KeyStorageType, _Key, _InputIterator>::_Ite(__first),
140 _STLP_TYPENAME _STLP_PRIV _IteWrapper<_KeyStorageType, _Key, _InputIterator>::_Ite(__last));
141# else
142 _M_t.insert_unique(__first, __last);
143# endif
144 }
145
146# if defined (_STLP_NEEDS_EXTRA_TEMPLATE_CONSTRUCTORS)
147 template <class _InputIterator>
148 set(_InputIterator __first, _InputIterator __last, const _Compare& __comp)
149 : _M_t(__comp, _StorageTypeAlloc()) {
150# if defined (_STLP_USE_ITERATOR_WRAPPER)
151 _M_t.insert_unique(_STLP_TYPENAME _STLP_PRIV _IteWrapper<_KeyStorageType, _Key, _InputIterator>::_Ite(__first),
152 _STLP_TYPENAME _STLP_PRIV _IteWrapper<_KeyStorageType, _Key, _InputIterator>::_Ite(__last));
153# else
154 _M_t.insert_unique(__first, __last);
155# endif
156 }
157# endif
158 template <class _InputIterator>
159 set(_InputIterator __first, _InputIterator __last, const _Compare& __comp,
162# if defined (_STLP_USE_ITERATOR_WRAPPER)
163 _M_t.insert_unique(_STLP_TYPENAME _STLP_PRIV _IteWrapper<_KeyStorageType, _Key, _InputIterator>::_Ite(__first),
164 _STLP_TYPENAME _STLP_PRIV _IteWrapper<_KeyStorageType, _Key, _InputIterator>::_Ite(__last));
165# else
166 _M_t.insert_unique(__first, __last);
167# endif
168 }
169#else
170 set(const value_type* __first, const value_type* __last)
171 : _M_t(_Compare(), _StorageTypeAlloc()) {
172 _M_t.insert_unique(cast_traits::to_storage_type_cptr(__first),
173 cast_traits::to_storage_type_cptr(__last));
174 }
175
176 set(const value_type* __first, const value_type* __last,
177 const _Compare& __comp, const allocator_type& __a = allocator_type())
179 _M_t.insert_unique(cast_traits::to_storage_type_cptr(__first),
180 cast_traits::to_storage_type_cptr(__last));
181 }
182
184 : _M_t(_Compare(), _StorageTypeAlloc())
185 { _M_t.insert_unique(_S_to_storage_ite(__first), _S_to_storage_ite(__last)); }
186
188 const _Compare& __comp, const allocator_type& __a = allocator_type())
190 { _M_t.insert_unique(_S_to_storage_ite(__first), _S_to_storage_ite(__last)); }
191#endif /* _STLP_MEMBER_TEMPLATES */
192
193 set(const _Self& __x) : _M_t(__x._M_t) {}
194
195#if !defined (_STLP_NO_MOVE_SEMANTIC)
198#endif
199
200 _Self& operator=(const _Self& __x) {
201 _M_t = __x._M_t;
202 return *this;
203 }
204
205 // accessors:
206 key_compare key_comp() const { return _M_t.key_comp(); }
207 value_compare value_comp() const { return _M_t.key_comp(); }
209 { return _STLP_CONVERT_ALLOCATOR(_M_t.get_allocator(), value_type); }
210
211 iterator begin() { return _S_to_value_ite(_M_t.begin()); }
212 iterator end() { return _S_to_value_ite(_M_t.end()); }
213 const_iterator begin() const { return _S_to_value_ite(_M_t.begin()); }
214 const_iterator end() const { return _S_to_value_ite(_M_t.end()); }
219 bool empty() const { return _M_t.empty(); }
220 size_type size() const { return _M_t.size(); }
221 size_type max_size() const { return _M_t.max_size(); }
222 void swap(_Self& __x) { _M_t.swap(__x._M_t); }
223#if defined (_STLP_USE_PARTIAL_SPEC_WORKAROUND) && !defined (_STLP_FUNCTION_TMPL_PARTIAL_ORDER)
224 void _M_swap_workaround(_Self& __x) { swap(__x); }
225#endif
226
227 // insert/erase
229 pair<base_iterator, bool> ret = _M_t.insert_unique(cast_traits::to_storage_type_cref(__x));
230 return pair<iterator, bool>(_S_to_value_ite(ret.first), ret.second);
231 }
233 { return _S_to_value_ite(_M_t.insert_unique(_S_to_storage_ite(__pos), cast_traits::to_storage_type_cref(__x))); }
234
235#if defined (_STLP_MEMBER_TEMPLATES)
236 template <class _InputIterator>
237 void insert(_InputIterator __first, _InputIterator __last) {
238# if defined (_STLP_USE_ITERATOR_WRAPPER)
239 _M_t.insert_unique(_STLP_TYPENAME _STLP_PRIV _IteWrapper<_KeyStorageType, _Key, _InputIterator>::_Ite(__first),
240 _STLP_TYPENAME _STLP_PRIV _IteWrapper<_KeyStorageType, _Key, _InputIterator>::_Ite(__last));
241# else
242 _M_t.insert_unique(__first, __last);
243# endif
244 }
245#else
247 { _M_t.insert_unique(_S_to_storage_ite(__first), _S_to_storage_ite(__last)); }
248 void insert(const value_type* __first, const value_type* __last) {
249 _M_t.insert_unique(cast_traits::to_storage_type_cptr(__first),
250 cast_traits::to_storage_type_cptr(__last));
251 }
252#endif
253 void erase(iterator __pos)
254 { _M_t.erase(_S_to_storage_ite(__pos)); }
256 { return _M_t.erase_unique(cast_traits::to_storage_type_cref(__x)); }
258 { _M_t.erase(_S_to_storage_ite(__first), _S_to_storage_ite(__last)); }
259 void clear() { _M_t.clear(); }
260
261 // set operations:
263 const_iterator find(const _KT& __x) const
264 { return _S_to_value_ite(_M_t.find(cast_traits::to_storage_type_crefT(__x))); }
266 iterator find(const _KT& __x)
267 { return _S_to_value_ite(_M_t.find(cast_traits::to_storage_type_crefT(__x))); }
269 size_type count(const _KT& __x) const
270 { return _M_t.find(cast_traits::to_storage_type_crefT(__x)) == _M_t.end() ? 0 : 1; }
272 iterator lower_bound(const _KT& __x)
273 { return _S_to_value_ite(_M_t.lower_bound(cast_traits::to_storage_type_crefT(__x))); }
275 const_iterator lower_bound(const _KT& __x) const
276 { return _S_to_value_ite(_M_t.lower_bound(cast_traits::to_storage_type_crefT(__x))); }
278 iterator upper_bound(const _KT& __x)
279 { return _S_to_value_ite(_M_t.upper_bound(cast_traits::to_storage_type_crefT(__x))); }
281 const_iterator upper_bound(const _KT& __x) const
282 { return _S_to_value_ite(_M_t.upper_bound(cast_traits::to_storage_type_crefT(__x))); }
286 __ret = _M_t.equal_range(cast_traits::to_storage_type_crefT(__x));
288 _S_to_value_ite(__ret.second));
289 }
293 __ret = _M_t.equal_range_unique(cast_traits::to_storage_type_crefT(__x));
295 _S_to_value_ite(__ret.second));
296 }
297};
298
299//Specific iterator traits creation
300_STLP_CREATE_ITERATOR_TRAITS(MultisetTraitsT, Const_traits)
301
302template <class _Key, _STLP_DFL_TMPL_PARAM(_Compare, less<_Key>),
303 _STLP_DFL_TMPL_PARAM(_Alloc, allocator<_Key>) >
304class multiset
305#if defined (_STLP_USE_PARTIAL_SPEC_WORKAROUND)
306 : public __stlport_class<multiset<_Key, _Compare, _Alloc> >
307#endif
308{
309#if !defined (__BORLANDC__)
313#else
316#endif
319
321public:
322 // typedefs:
323 typedef _Key key_type;
324 typedef _Key value_type;
325 typedef _Compare key_compare;
326 typedef _Compare value_compare;
327
328protected:
329 //Specific iterator traits creation
330 typedef _STLP_PRIV _MultisetTraitsT<value_type> _MultisetTraits;
334
335 typedef _STLP_PRIV _MultisetTraitsT<_KeyStorageType> _MultisetStorageTraits;
336public:
337 //dums: need the following public for the __move_traits framework
341
342private:
343 typedef typename _Rep_type::iterator base_iterator;
344 typedef typename _Rep_type::const_iterator const_base_iterator;
345
346public:
347 typedef typename _Priv_Rep_type::pointer pointer;
348 typedef typename _Priv_Rep_type::const_pointer const_pointer;
349 typedef typename _Priv_Rep_type::reference reference;
350 typedef typename _Priv_Rep_type::const_reference const_reference;
351 typedef typename _Priv_Rep_type::iterator iterator;
352 typedef typename _Priv_Rep_type::const_iterator const_iterator;
353 typedef typename _Priv_Rep_type::reverse_iterator reverse_iterator;
354 typedef typename _Priv_Rep_type::const_reverse_iterator const_reverse_iterator;
355 typedef typename _Priv_Rep_type::size_type size_type;
356 typedef typename _Priv_Rep_type::difference_type difference_type;
357 typedef typename _Priv_Rep_type::allocator_type allocator_type;
358
359private:
360 _Rep_type _M_t; // red-black tree representing multiset
362
363#if defined (_STLP_DEBUG)
365 { return iterator(__ite._Owner(), __ite._M_iterator._M_node); }
367 { return base_iterator(__ite._Owner(), __ite._M_iterator._M_node); }
368#else
370 { return iterator(__ite._M_node); }
372 { return base_iterator(__ite._M_node); }
373#endif
374
375public:
376 multiset() : _M_t(_Compare(), _StorageTypeAlloc()) {}
377 explicit multiset(const _Compare& __comp,
378 const allocator_type& __a = allocator_type())
380
381#if defined (_STLP_MEMBER_TEMPLATES)
382 template <class _InputIterator>
383 multiset(_InputIterator __first, _InputIterator __last)
384 : _M_t(_Compare(), _StorageTypeAlloc()) {
385# if defined (_STLP_USE_ITERATOR_WRAPPER)
386 _M_t.insert_equal(_STLP_TYPENAME _STLP_PRIV _IteWrapper<_KeyStorageType, _Key, _InputIterator>::_Ite(__first),
387 _STLP_TYPENAME _STLP_PRIV _IteWrapper<_KeyStorageType, _Key, _InputIterator>::_Ite(__last));
388# else
389 _M_t.insert_equal(__first, __last);
390# endif
391 }
392
393# if defined (_STLP_NEEDS_EXTRA_TEMPLATE_CONSTRUCTORS)
394 template <class _InputIterator>
395 multiset(_InputIterator __first, _InputIterator __last,
396 const _Compare& __comp)
397 : _M_t(__comp, _StorageTypeAlloc()) {
398# if defined (_STLP_USE_ITERATOR_WRAPPER)
399 _M_t.insert_equal(_STLP_TYPENAME _STLP_PRIV _IteWrapper<_KeyStorageType, _Key, _InputIterator>::_Ite(__first),
400 _STLP_TYPENAME _STLP_PRIV _IteWrapper<_KeyStorageType, _Key, _InputIterator>::_Ite(__last));
401# else
402 _M_t.insert_equal(__first, __last);
403# endif
404 }
405# endif
406 template <class _InputIterator>
407 multiset(_InputIterator __first, _InputIterator __last,
408 const _Compare& __comp,
411# if defined (_STLP_USE_ITERATOR_WRAPPER)
412 _M_t.insert_equal(_STLP_TYPENAME _STLP_PRIV _IteWrapper<_KeyStorageType, _Key, _InputIterator>::_Ite(__first),
413 _STLP_TYPENAME _STLP_PRIV _IteWrapper<_KeyStorageType, _Key, _InputIterator>::_Ite(__last));
414# else
415 _M_t.insert_equal(__first, __last);
416# endif
417 }
418
419#else
420 multiset(const value_type* __first, const value_type* __last)
421 : _M_t(_Compare(), _StorageTypeAlloc()) {
422 _M_t.insert_equal(cast_traits::to_storage_type_cptr(__first),
423 cast_traits::to_storage_type_cptr(__last));
424 }
425
426 multiset(const value_type* __first, const value_type* __last,
427 const _Compare& __comp,
428 const allocator_type& __a = allocator_type())
430 _M_t.insert_equal(cast_traits::to_storage_type_cptr(__first),
431 cast_traits::to_storage_type_cptr(__last));
432 }
433
435 : _M_t(_Compare(), _StorageTypeAlloc())
436 { _M_t.insert_equal(_S_to_storage_ite(__first), _S_to_storage_ite(__last)); }
437
439 const _Compare& __comp,
440 const allocator_type& __a = allocator_type())
442 { _M_t.insert_equal(_S_to_storage_ite(__first), _S_to_storage_ite(__last)); }
443#endif /* _STLP_MEMBER_TEMPLATES */
444
445 multiset(const _Self& __x)
446 : _M_t(__x._M_t) {}
447
448 _Self& operator=(const _Self& __x) {
449 _M_t = __x._M_t;
450 return *this;
451 }
452
453#if !defined (_STLP_NO_MOVE_SEMANTIC)
456#endif
457
458 // accessors:
459 key_compare key_comp() const { return _M_t.key_comp(); }
460 value_compare value_comp() const { return _M_t.key_comp(); }
462 { return _STLP_CONVERT_ALLOCATOR(_M_t.get_allocator(), value_type); }
463
464 iterator begin() { return _S_to_value_ite(_M_t.begin()); }
465 iterator end() { return _S_to_value_ite(_M_t.end()); }
466 const_iterator begin() const { return _S_to_value_ite(_M_t.begin()); }
467 const_iterator end() const { return _S_to_value_ite(_M_t.end()); }
472 bool empty() const { return _M_t.empty(); }
473 size_type size() const { return _M_t.size(); }
474 size_type max_size() const { return _M_t.max_size(); }
475 void swap(_Self& __x) { _M_t.swap(__x._M_t); }
476#if defined (_STLP_USE_PARTIAL_SPEC_WORKAROUND) && !defined (_STLP_FUNCTION_TMPL_PARTIAL_ORDER)
477 void _M_swap_workaround(_Self& __x) { swap(__x); }
478#endif
479
480 // insert/erase
482 { return _S_to_value_ite(_M_t.insert_equal(cast_traits::to_storage_type_cref(__x))); }
483 iterator insert(iterator __pos, const value_type& __x) {
484 return _S_to_value_ite(_M_t.insert_equal(_S_to_storage_ite(__pos),
485 cast_traits::to_storage_type_cref(__x)));
486 }
487
488#if defined (_STLP_MEMBER_TEMPLATES)
489 template <class _InputIterator>
490 void insert(_InputIterator __first, _InputIterator __last) {
491# if defined (_STLP_USE_ITERATOR_WRAPPER)
492 _M_t.insert_equal(_STLP_TYPENAME _STLP_PRIV _IteWrapper<_KeyStorageType, _Key, _InputIterator>::_Ite(__first),
493 _STLP_TYPENAME _STLP_PRIV _IteWrapper<_KeyStorageType, _Key, _InputIterator>::_Ite(__last));
494# else
495 _M_t.insert_equal(__first, __last);
496# endif
497 }
498#else
499 void insert(const value_type* __first, const value_type* __last) {
500 _M_t.insert_equal(cast_traits::to_storage_type_cptr(__first),
501 cast_traits::to_storage_type_cptr(__last));
502 }
504 { _M_t.insert_equal(_S_to_storage_ite(__first), _S_to_storage_ite(__last)); }
505#endif /* _STLP_MEMBER_TEMPLATES */
506
507 void erase(iterator __pos)
508 { _M_t.erase(_S_to_storage_ite(__pos)); }
510 { return _M_t.erase(cast_traits::to_storage_type_cref(__x)); }
512 { _M_t.erase(_S_to_storage_ite(__first), _S_to_storage_ite(__last)); }
513 void clear() { _M_t.clear(); }
514
515 // multiset operations:
516
518 iterator find(const _KT& __x)
519 { return _S_to_value_ite(_M_t.find(cast_traits::to_storage_type_crefT(__x))); }
521 const_iterator find(const _KT& __x) const
522 { return _S_to_value_ite(_M_t.find(cast_traits::to_storage_type_crefT(__x))); }
524 size_type count(const _KT& __x) const
525 { return _M_t.count(cast_traits::to_storage_type_crefT(__x)); }
527 iterator lower_bound(const _KT& __x)
528 { return _S_to_value_ite(_M_t.lower_bound(cast_traits::to_storage_type_crefT(__x))); }
530 const_iterator lower_bound(const _KT& __x) const
531 { return _S_to_value_ite(_M_t.lower_bound(cast_traits::to_storage_type_crefT(__x))); }
533 iterator upper_bound(const _KT& __x)
534 { return _S_to_value_ite(_M_t.upper_bound(cast_traits::to_storage_type_crefT(__x))); }
536 const_iterator upper_bound(const _KT& __x) const
537 { return _S_to_value_ite(_M_t.upper_bound(cast_traits::to_storage_type_crefT(__x))); }
541 __ret = _M_t.equal_range(cast_traits::to_storage_type_crefT(__x));
543 _S_to_value_ite(__ret.second));
544 }
548 __ret = _M_t.equal_range(cast_traits::to_storage_type_crefT(__x));
550 _S_to_value_ite(__ret.second));
551 }
552};
553
554#if defined (__BORLANDC__) || defined (__DMC__)
555# undef typename
556#endif
557
559
560#endif /* _STLP_PTR_SPECIALIZED_SET_H */
561
562// Local Variables:
563// mode:C++
564// End:
_STLP_INLINE_LOOP _InputIter __last
Definition: _algo.h:68
#define _STLP_CONVERT_ALLOCATOR(__a, _Tp)
Definition: _alloc.h:183
#define _Alloc
Definition: _bvector.h:330
#define _STLP_PRIV
Definition: _dm.h:70
#define _STLP_CREATE_ITERATOR_TRAITS(Motif, Traits)
void get(int argc, const char *argv[])
Definition: cmds.c:480
Definition: _set.h:220
multiset(const _Self &__x)
Definition: _set.h:445
_STLP_PRIV _Rb_tree< key_type, key_compare, value_type, _STLP_PRIV _Identity< value_type >, _MultisetTraits, _Alloc > _Rep_type
Definition: _set.h:238
const_reverse_iterator rend() const
Definition: _set.h:471
_Compare value_compare
Definition: _set.h:326
_Priv_Rep_type::reference reference
Definition: _set.h:349
_Priv_Rep_type::iterator iterator
Definition: _set.h:351
_AssocStorageTypes::_KeyStorageType _KeyStorageType
Definition: _set.h:311
void erase(iterator __first, iterator __last)
Definition: _set.h:511
void insert(const_iterator __first, const_iterator __last)
Definition: _set.h:503
_Alloc_traits< _KeyStorageType, _Alloc >::allocator_type _StorageTypeAlloc
Definition: _set.h:317
size_type max_size() const
Definition: _set.h:474
_Rep_type::size_type size_type
Definition: _set.h:248
_STLP_TEMPLATE_FOR_CONT_EXT pair< const_iterator, const_iterator > equal_range(const _KT &__x) const
Definition: _set.h:546
_STLP_TEMPLATE_FOR_CONT_EXT size_type count(const _KT &__x) const
Definition: _set.h:524
const_iterator end() const
Definition: _set.h:467
_Priv_Rep_type::const_reference const_reference
Definition: _set.h:350
reverse_iterator rbegin()
Definition: _set.h:468
_STLP_PRIV _CastTraits< _KeyStorageType, _Key > cast_traits
Definition: _set.h:318
multiset(const _Compare &__comp, const allocator_type &__a=allocator_type())
Definition: _set.h:377
size_type size() const
Definition: _set.h:473
multiset(const_iterator __first, const_iterator __last)
Definition: _set.h:434
_Priv_Rep_type::allocator_type allocator_type
Definition: _set.h:357
iterator insert(iterator __pos, const value_type &__x)
Definition: _set.h:483
_STLP_TEMPLATE_FOR_CONT_EXT iterator lower_bound(const _KT &__x)
Definition: _set.h:527
_Priv_Rep_type::reverse_iterator reverse_iterator
Definition: _set.h:353
_Rep_type::const_reverse_iterator const_reverse_iterator
Definition: _set.h:247
_Priv_Rep_type::const_pointer const_pointer
Definition: _set.h:348
multiset(__move_source< _Self > src)
Definition: _set.h:454
_Rep_type::allocator_type allocator_type
Definition: _set.h:250
_STLP_TEMPLATE_FOR_CONT_EXT iterator upper_bound(const _KT &__x)
Definition: _set.h:533
_AssocStorageTypes::_CompareStorageType _CompareStorageType
Definition: _set.h:312
const_iterator begin() const
Definition: _set.h:466
bool empty() const
Definition: _set.h:472
_Rep_type::iterator base_iterator
Definition: _set.h:343
void swap(_Self &__x)
Definition: _set.h:475
_Key value_type
Definition: _set.h:324
_STLP_TEMPLATE_FOR_CONT_EXT iterator find(const _KT &__x)
Definition: _set.h:518
_Rep_type::const_iterator const_base_iterator
Definition: _set.h:344
iterator end()
Definition: _set.h:465
void erase(iterator __pos)
Definition: _set.h:507
_Priv_Rep_type::const_iterator const_iterator
Definition: _set.h:352
iterator insert(const value_type &__x)
Definition: _set.h:481
multiset(const value_type *__first, const value_type *__last, const _Compare &__comp, const allocator_type &__a=allocator_type())
Definition: _set.h:426
_Compare key_compare
Definition: _set.h:325
_Self & operator=(const _Self &__x)
Definition: _set.h:448
_STLP_PRIV _MultisetTraitsT< value_type > _MultisetTraits
Definition: _set.h:330
_Key key_type
Definition: _set.h:323
_STLP_TEMPLATE_FOR_CONT_EXT const_iterator find(const _KT &__x) const
Definition: _set.h:521
_STLP_TEMPLATE_FOR_CONT_EXT pair< iterator, iterator > equal_range(const _KT &__x)
Definition: _set.h:539
void insert(const value_type *__first, const value_type *__last)
Definition: _set.h:499
_STLP_PRIV _Rb_tree< _KeyStorageType, _CompareStorageType, _KeyStorageType, _STLP_PRIV _Identity< _KeyStorageType >, _MultisetStorageTraits, _StorageTypeAlloc > _Rep_type
Definition: _set.h:340
iterator begin()
Definition: _set.h:464
_Rep_type::reverse_iterator reverse_iterator
Definition: _set.h:246
reverse_iterator rend()
Definition: _set.h:469
key_compare key_comp() const
Definition: _set.h:459
allocator_type get_allocator() const
Definition: _set.h:461
_Rep_type::iterator iterator
Definition: _set.h:244
_Priv_Rep_type::pointer pointer
Definition: _set.h:347
void clear()
Definition: _set.h:513
_STLP_TEMPLATE_FOR_CONT_EXT const_iterator lower_bound(const _KT &__x) const
Definition: _set.h:530
multiset< _Key, _Compare, _Alloc > _Self
Definition: _set.h:320
_STLP_PRIV _MultisetTraitsT< _KeyStorageType > _MultisetStorageTraits
Definition: _set.h:335
multiset(const_iterator __first, const_iterator __last, const _Compare &__comp, const allocator_type &__a=allocator_type())
Definition: _set.h:438
_Priv_Rep_type::size_type size_type
Definition: _set.h:355
multiset()
Definition: _set.h:376
_Rep_type _M_t
Definition: _set.h:253
const_reverse_iterator rbegin() const
Definition: _set.h:470
_Priv_Rep_type::const_reverse_iterator const_reverse_iterator
Definition: _set.h:354
multiset(const value_type *__first, const value_type *__last)
Definition: _set.h:420
static base_iterator _S_to_storage_ite(const_iterator __ite)
Definition: _set.h:371
_STLP_TEMPLATE_FOR_CONT_EXT const_iterator upper_bound(const _KT &__x) const
Definition: _set.h:536
_Priv_Rep_type::difference_type difference_type
Definition: _set.h:356
_STLP_PRIV _Rb_tree< key_type, key_compare, value_type, _STLP_PRIV _Identity< value_type >, _MultisetTraits, _Alloc > _Priv_Rep_type
Definition: _set.h:333
_STLP_PRIV _AssocStorageTypes< _Key, _Compare > _AssocStorageTypes
Definition: _set.h:310
value_compare value_comp() const
Definition: _set.h:460
size_type erase(const key_type &__x)
Definition: _set.h:509
_Rep_type::const_iterator const_iterator
Definition: _set.h:245
static iterator _S_to_value_ite(const_base_iterator __ite)
Definition: _set.h:369
Definition: _set.h:50
key_compare key_comp() const
Definition: _set.h:206
set(const value_type *__first, const value_type *__last, const _Compare &__comp, const allocator_type &__a=allocator_type())
Definition: _set.h:176
set(const_iterator __first, const_iterator __last)
Definition: _set.h:183
void erase(iterator __first, iterator __last)
Definition: _set.h:257
_Priv_Rep_type::allocator_type allocator_type
Definition: _set.h:110
_Key key_type
Definition: _set.h:75
_Rep_type::reverse_iterator reverse_iterator
Definition: _set.h:75
_STLP_TEMPLATE_FOR_CONT_EXT const_iterator lower_bound(const _KT &__x) const
Definition: _set.h:275
value_compare value_comp() const
Definition: _set.h:207
_STLP_TEMPLATE_FOR_CONT_EXT iterator upper_bound(const _KT &__x)
Definition: _set.h:278
_Priv_Rep_type::const_reference const_reference
Definition: _set.h:103
_Priv_Rep_type::iterator iterator
Definition: _set.h:104
set(__move_source< _Self > src)
Definition: _set.h:196
_STLP_PRIV _AssocStorageTypes< _Key, _Compare > _AssocStorageTypes
Definition: _set.h:63
size_type max_size() const
Definition: _set.h:221
static base_iterator _S_to_storage_ite(const_iterator __ite)
Definition: _set.h:124
set()
Definition: _set.h:129
_STLP_PRIV _CastTraits< _KeyStorageType, _Key > cast_traits
Definition: _set.h:71
iterator insert(iterator __pos, const value_type &__x)
Definition: _set.h:232
set(const _Self &__x)
Definition: _set.h:193
bool empty() const
Definition: _set.h:219
const_reverse_iterator rend() const
Definition: _set.h:218
const_iterator begin() const
Definition: _set.h:213
void erase(iterator __pos)
Definition: _set.h:253
iterator end()
Definition: _set.h:212
_STLP_PRIV _SetTraitsT< _KeyStorageType > _SetStorageTraits
Definition: _set.h:87
_Priv_Rep_type::const_reverse_iterator const_reverse_iterator
Definition: _set.h:107
void insert(const_iterator __first, const_iterator __last)
Definition: _set.h:246
_STLP_TEMPLATE_FOR_CONT_EXT pair< iterator, iterator > equal_range(const _KT &__x)
Definition: _set.h:284
_Rep_type::size_type size_type
Definition: _set.h:77
const_iterator end() const
Definition: _set.h:214
_STLP_PRIV _Rb_tree< _KeyStorageType, _CompareStorageType, _KeyStorageType, _STLP_PRIV _Identity< _KeyStorageType >, _SetStorageTraits, _StorageTypeAlloc > _Rep_type
Definition: _set.h:93
iterator begin()
Definition: _set.h:211
_STLP_PRIV _SetTraitsT< value_type > _SetTraits
Definition: _set.h:82
_STLP_TEMPLATE_FOR_CONT_EXT pair< const_iterator, const_iterator > equal_range(const _KT &__x) const
Definition: _set.h:291
_Priv_Rep_type::difference_type difference_type
Definition: _set.h:109
_STLP_PRIV _Rb_tree< key_type, key_compare, value_type, _STLP_PRIV _Identity< value_type >, _SetTraits, _Alloc > _Rep_type
Definition: _set.h:67
set(const _Compare &__comp, const allocator_type &__a=allocator_type())
Definition: _set.h:130
pair< iterator, bool > insert(const value_type &__x)
Definition: _set.h:228
_AssocStorageTypes::_CompareStorageType _CompareStorageType
Definition: _set.h:65
const_reverse_iterator rbegin() const
Definition: _set.h:217
static iterator _S_to_value_ite(const_base_iterator __ite)
Definition: _set.h:122
set(const_iterator __first, const_iterator __last, const _Compare &__comp, const allocator_type &__a=allocator_type())
Definition: _set.h:187
_Priv_Rep_type::const_iterator const_iterator
Definition: _set.h:105
_Priv_Rep_type::const_pointer const_pointer
Definition: _set.h:101
_Rep_type::iterator base_iterator
Definition: _set.h:96
void clear()
Definition: _set.h:259
_Rep_type::const_reverse_iterator const_reverse_iterator
Definition: _set.h:76
_Rep_type _M_t
Definition: _set.h:82
_STLP_PRIV _Rb_tree< key_type, key_compare, value_type, _STLP_PRIV _Identity< value_type >, _SetTraits, _Alloc > _Priv_Rep_type
Definition: _set.h:85
reverse_iterator rbegin()
Definition: _set.h:215
allocator_type get_allocator() const
Definition: _set.h:208
_Rep_type::allocator_type allocator_type
Definition: _set.h:79
_Priv_Rep_type::pointer pointer
Definition: _set.h:100
_Priv_Rep_type::reference reference
Definition: _set.h:102
_Priv_Rep_type::size_type size_type
Definition: _set.h:108
_Compare value_compare
Definition: _set.h:78
void swap(_Self &__x)
Definition: _set.h:222
_STLP_TEMPLATE_FOR_CONT_EXT iterator find(const _KT &__x)
Definition: _set.h:266
_STLP_TEMPLATE_FOR_CONT_EXT iterator lower_bound(const _KT &__x)
Definition: _set.h:272
_STLP_TEMPLATE_FOR_CONT_EXT size_type count(const _KT &__x) const
Definition: _set.h:269
_Rep_type::const_iterator const_iterator
Definition: _set.h:74
_Priv_Rep_type::reverse_iterator reverse_iterator
Definition: _set.h:106
_Key value_type
Definition: _set.h:76
size_type size() const
Definition: _set.h:220
reverse_iterator rend()
Definition: _set.h:216
_Self & operator=(const _Self &__x)
Definition: _set.h:200
_STLP_TEMPLATE_FOR_CONT_EXT const_iterator upper_bound(const _KT &__x) const
Definition: _set.h:281
_Compare key_compare
Definition: _set.h:77
void insert(const value_type *__first, const value_type *__last)
Definition: _set.h:248
set< _Key, _Compare, _Alloc > _Self
Definition: _set.h:73
_STLP_TEMPLATE_FOR_CONT_EXT const_iterator find(const _KT &__x) const
Definition: _set.h:263
set(const value_type *__first, const value_type *__last)
Definition: _set.h:170
_Rep_type::const_iterator const_base_iterator
Definition: _set.h:97
size_type erase(const key_type &__x)
Definition: _set.h:255
_AssocStorageTypes::_KeyStorageType _KeyStorageType
Definition: _set.h:64
_Alloc_traits< _KeyStorageType, _Alloc >::allocator_type _StorageTypeAlloc
Definition: _set.h:70
_Rep_type::iterator iterator
Definition: _set.h:73
#define _STLP_TEMPLATE_FOR_CONT_EXT
Definition: features.h:623
#define _STLP_MOVE_TO_STD_NAMESPACE
Definition: features.h:525
#define _STLP_TYPENAME
Definition: features.h:612
#define _STLP_ALLOCATOR_TYPE_DFL
Definition: features.h:691
#define _STLP_KEY_TYPE_FOR_CONT_EXT(type)
Definition: features.h:622
#define _STLP_CLASS_DECLSPEC
Definition: features.h:983
#define _STLP_EXPORT_TEMPLATE_CLASS
Definition: features.h:987
#define _STLP_EXPORT
Definition: features.h:951
#define _STLP_BEGIN_NAMESPACE
Definition: features.h:501
#define _STLP_END_NAMESPACE
Definition: features.h:503
#define _STLP_MOVE_TO_PRIV_NAMESPACE
Definition: features.h:524
GLenum src
Definition: glext.h:6340
if(dx< 0)
Definition: linetemp.h:194
#define swap(a, b)
Definition: qsort.c:63
_Rebind_type::other allocator_type
Definition: _alloc.h:201
__select< is_default_less &&ptr_type, _BinaryPredWrapper< _KeyStorageType, _Tp, _Compare >, _Compare >::_Ret _CompareStorageType
Definition: _tools.h:196
__select< is_default_less, _SType, _Tp >::_Ret _KeyStorageType
Definition: _tools.h:193
Definition: _pair.h:47
_T2 second
Definition: _pair.h:52
_T1 first
Definition: _pair.h:51
int ret
static int insert
Definition: xmllint.c:138