BDE 4.14.0 Production release
Loading...
Searching...
No Matches
bslstl.h
Go to the documentation of this file.
1/// @file bslstl.h
2///
3///
4/// @defgroup bslstl Package bslstl
5/// @brief Basic Standard Library STL (bslstl)
6/// @addtogroup bsl
7/// @{
8/// @addtogroup bslstl
9/// [bslstl]: group__bslstl.html
10/// @{
11///
12/// # Purpose {#bslstl-purpose}
13/// Provide replacement classes for STL constructs.
14///
15/// # Mnemonic {#bslstl-mnemonic}
16/// Basic Standard Library STL (bslstl)
17///
18/// # Description {#bslstl-description}
19/// This package mainly provides replacement classes for STL
20/// constructs that required substantial modification to (inter)operate with BDE
21/// libraries. In addition to STL replacement classes, this package also provides
22/// helper components for the STL implementation classes. Finally, SGI extensions
23/// that are widely used within Bloomberg can also be found in this package.
24///
25/// In general, the components in this package conform to the STL interface.
26/// However, the components (and hence the headers) are intended for private use
27/// only. Clients should use the standard headers directly (e.g., include
28/// '<bsl_vector.h>' instead of '<bslstl_vector.h>').
29///
30/// ## Hierarchical Synopsis
31///
32/// The 'bslstl' package currently has 126 components having 10 levels of physical
33/// dependency. The list below shows the hierarchical ordering of the components.
34/// The order of components within each level is not architecturally significant,
35/// just alphabetical.
36/// @code
37/// 10. bslstl_ownerequal
38/// bslstl_ownerhash
39/// bslstl_ownerless
40/// bslstl_stoptoken
41/// bslstl_typeindex
42///
43/// 9. bslstl_map_test1 !PRIVATE!
44/// bslstl_map_test2 !PRIVATE!
45/// bslstl_map_test3 !PRIVATE!
46/// bslstl_multimap_test !PRIVATE!
47/// bslstl_multiset_test !PRIVATE!
48/// bslstl_set_test !PRIVATE!
49/// bslstl_sharedptr
50///
51/// 8. bslstl_map
52/// bslstl_multimap
53/// bslstl_multiset
54/// bslstl_osyncstream
55/// bslstl_set
56///
57/// 7. bslstl_boyermoorehorspoolsearcher
58/// bslstl_istringstream
59/// bslstl_mapcomparator
60/// bslstl_ostringstream
61/// bslstl_queue
62/// bslstl_setcomparator
63/// bslstl_stack
64/// bslstl_stringstream
65/// bslstl_syncbuf
66/// bslstl_treenodepool
67/// bslstl_unorderedmap_test !PRIVATE!
68/// bslstl_unorderedmultimap_test !PRIVATE!
69/// bslstl_unorderedmultiset_test !PRIVATE!
70/// bslstl_unorderedset_test !PRIVATE!
71///
72/// 6. bslstl_bitset
73/// bslstl_defaultsearcher
74/// bslstl_deque
75/// bslstl_iomanip
76/// bslstl_priorityqueue
77/// bslstl_span
78/// bslstl_string_test !PRIVATE!
79/// bslstl_stringbuf
80/// bslstl_stringref
81/// bslstl_treenode
82/// bslstl_unorderedmap
83/// bslstl_unorderedmultimap
84/// bslstl_unorderedmultiset
85/// bslstl_unorderedset
86/// bslstl_variant
87///
88/// 5. bslstl_array
89/// bslstl_function
90/// bslstl_hashtable
91/// bslstl_list
92/// bslstl_randomaccessiterator
93/// bslstl_string
94/// bslstl_systemerror
95/// bslstl_vector
96///
97/// 4. bslstl_algorithm
98/// bslstl_bidirectionaliterator
99/// bslstl_charconv
100/// bslstl_error
101/// bslstl_function_invokerutil !PRIVATE!
102/// bslstl_hashtablebucketiterator
103/// bslstl_hashtableiterator
104/// bslstl_iteratorutil
105/// bslstl_ostream
106/// bslstl_stringrefdata
107///
108/// 3. bslstl_bidirectionalnodepool
109/// bslstl_chrono
110/// bslstl_errc
111/// bslstl_forwarditerator
112/// bslstl_function_rep !PRIVATE!
113/// bslstl_ios
114/// bslstl_optional
115/// bslstl_pair
116/// bslstl_stringview
117/// bslstl_treeiterator
118///
119/// 2. bslstl_algorithmworkaround !DEPRECATED!
120/// bslstl_allocator !DEPRECATED!
121/// bslstl_badfunctioncall
122/// bslstl_badoptionalaccess
123/// bslstl_badvariantaccess
124/// bslstl_badweakptr
125/// bslstl_compare
126/// bslstl_complex
127/// bslstl_equalto
128/// bslstl_exception
129/// bslstl_function_isreferencecompatible !PRIVATE!
130/// bslstl_function_smallobjectoptimization !PRIVATE!
131/// bslstl_hash
132/// bslstl_inplace
133/// bslstl_iosfwd
134/// bslstl_iserrorcodeenum
135/// bslstl_iserrorconditionenum
136/// bslstl_iterator
137/// bslstl_monostate
138/// bslstl_ratio
139/// bslstl_referencewrapper
140/// bslstl_sharedptrallocateinplacerep
141/// bslstl_sharedptrallocateoutofplacerep
142/// bslstl_simplepool
143/// bslstl_stdexceptutil
144/// bslstl_stopstate
145/// bslstl_syncbufbase
146/// bslstl_unorderedmapkeyconfiguration
147/// bslstl_unorderedsetkeyconfiguration
148/// bslstl_utility
149///
150/// 1. bslstl_bidirectionalnodepool_cpp03 !PRIVATE!
151/// bslstl_deque_cpp03 !PRIVATE!
152/// bslstl_function_cpp03 !PRIVATE!
153/// bslstl_function_invokerutil_cpp03 !PRIVATE!
154/// bslstl_hashtable_cpp03 !PRIVATE!
155/// bslstl_list_cpp03 !PRIVATE!
156/// bslstl_map_cpp03 !PRIVATE!
157/// bslstl_multimap_cpp03 !PRIVATE!
158/// bslstl_multiset_cpp03 !PRIVATE!
159/// bslstl_optional_cpp03 !PRIVATE!
160/// bslstl_priorityqueue_cpp03 !PRIVATE!
161/// bslstl_queue_cpp03 !PRIVATE!
162/// bslstl_set_cpp03 !PRIVATE!
163/// bslstl_sharedptr_cpp03 !PRIVATE!
164/// bslstl_stack_cpp03 !PRIVATE!
165/// bslstl_treenodepool_cpp03 !PRIVATE!
166/// bslstl_unorderedmap_cpp03 !PRIVATE!
167/// bslstl_unorderedmultimap_cpp03 !PRIVATE!
168/// bslstl_unorderedmultiset_cpp03 !PRIVATE!
169/// bslstl_unorderedset_cpp03 !PRIVATE!
170/// bslstl_variant_cpp03 !PRIVATE!
171/// bslstl_vector_cpp03 !PRIVATE!
172/// @endcode
173///
174/// ## Component Synopsis
175///
176/// @ref bslstl_algorithm :
177/// Provide implementations for algorithms not in the system library.
178///
179/// @ref bslstl_algorithmworkaround : !DEPRECATED!
180/// Provide a namespace for work arounds for the standard algorithms
181///
182/// @ref bslstl_allocator : !DEPRECATED!
183/// Provide an STL-compatible proxy for `bslma::Allocator` objects.
184///
185/// @ref bslstl_array :
186/// Provide an STL compliant array.
187///
188/// @ref bslstl_badfunctioncall :
189/// Provide an exception class thrown by `bsl::function`.
190///
191/// @ref bslstl_badoptionalaccess :
192/// Provide an exception class thrown by `bsl::optional`.
193///
194/// @ref bslstl_badvariantaccess :
195/// Provide an exception class thrown by `bsl::variant`.
196///
197/// @ref bslstl_badweakptr :
198/// Provide an exception class to indicate a weak_ptr has expired.
199///
200/// @ref bslstl_bidirectionaliterator :
201/// Provide a template to create STL-compliant bidirectional iterators.
202///
203/// @ref bslstl_bidirectionalnodepool :
204/// Provide efficient creation of nodes used in a node-based container.
205///
206/// 'bslstl_bidirectionalnodepool_cpp03': !PRIVATE!
207/// Provide C++03 implementation for bslstl_bidirectionalnodepool.h
208///
209/// @ref bslstl_bitset :
210/// Provide an STL-compliant bitset class.
211///
212/// @ref bslstl_boyermoorehorspoolsearcher :
213/// Provide an STL-compliant `boyer_moore_horspool_searcher` class.
214///
215/// @ref bslstl_charconv :
216/// Provide implementations for functions not in the system library.
217///
218/// @ref bslstl_chrono :
219/// Provide functionality of the corresponding C++ Standard header.
220///
221/// @ref bslstl_compare :
222/// Provide functionality of the corresponding C++ Standard header.
223///
224/// @ref bslstl_complex :
225/// Provide functionality of the corresponding C++ Standard header.
226///
227/// @ref bslstl_defaultsearcher :
228/// Provide an STL-compliant @ref default_searcher class.
229///
230/// @ref bslstl_deque :
231/// Provide an STL-compliant deque class.
232///
233/// 'bslstl_deque_cpp03': !PRIVATE!
234/// Provide C++03 implementation for bslstl_deque.h
235///
236/// @ref bslstl_equalto :
237/// Provide a binary functor conforming to the C++11 `equal_to` spec.
238///
239/// @ref bslstl_errc :
240/// Provide a standard compliant version of `errc`.
241///
242/// @ref bslstl_error :
243/// Provide standard compliant versions of <system_error> classes.
244///
245/// @ref bslstl_exception :
246/// Provide an implementation of @ref uncaught_exceptions .
247///
248/// @ref bslstl_forwarditerator :
249/// Provide a template to create STL-compliant forward iterators.
250///
251/// @ref bslstl_function :
252/// Provide a polymorphic function object with a specific prototype.
253///
254/// 'bslstl_function_cpp03': !PRIVATE!
255/// Provide C++03 implementation for bslstl_function.h
256///
257/// 'bslstl_function_invokerutil': !PRIVATE!
258/// Provide invoker adaptors for `bsl::function`
259///
260/// 'bslstl_function_invokerutil_cpp03': !PRIVATE!
261/// Provide C++03 implementation for bslstl_function_invokerutil.h
262///
263/// 'bslstl_function_isreferencecompatible': !PRIVATE!
264/// Provide a metafunction for substitutability of type references.
265///
266/// 'bslstl_function_rep': !PRIVATE!
267/// Provide a non-template, common implementation for `bsl::function`.
268///
269/// 'bslstl_function_smallobjectoptimization': !PRIVATE!
270/// Provide small-object optimization buffer for `bsl::function`.
271///
272/// @ref bslstl_hash :
273/// Provide a namespace for hash functions.
274///
275/// @ref bslstl_hashtable :
276/// Provide a hash-container with support for duplicate values.
277///
278/// 'bslstl_hashtable_cpp03': !PRIVATE!
279/// Provide C++03 implementation for bslstl_hashtable.h
280///
281/// @ref bslstl_hashtablebucketiterator :
282/// Provide an STL compliant iterator over hash table buckets.
283///
284/// @ref bslstl_hashtableiterator :
285/// Provide an STL compliant iterator for hash tables.
286///
287/// @ref bslstl_inplace :
288/// Provide a standard-compliant in place construction tag types.
289///
290/// @ref bslstl_iomanip :
291/// Provide BSL implementations for standard <iomanip> features.
292///
293/// 'bslstl_ios':
294/// Provide functionality of the corresponding C++ Standard header.
295///
296/// @ref bslstl_iosfwd :
297/// Provide forward declarations for Standard stream classes.
298///
299/// @ref bslstl_iserrorcodeenum :
300/// Provide a compliant standard `is_error_code_enum` trait.
301///
302/// @ref bslstl_iserrorconditionenum :
303/// Provide a compliant standard `is_error_condition_enum` trait.
304///
305/// @ref bslstl_istringstream :
306/// Provide a C++03-compatible `istringstream` class.
307///
308/// @ref bslstl_iterator :
309/// Provide basic iterator traits, adaptors, and utilities.
310///
311/// @ref bslstl_iteratorutil :
312/// Provide utilities operating on iterators and iterator ranges.
313///
314/// @ref bslstl_list :
315/// Provide an STL-compliant list class.
316///
317/// 'bslstl_list_cpp03': !PRIVATE!
318/// Provide C++03 implementation for bslstl_list.h
319///
320/// 'bslstl_map':
321/// Provide an STL-compliant map class.
322///
323/// 'bslstl_map_cpp03': !PRIVATE!
324/// Provide C++03 implementation for bslstl_map.h
325///
326/// 'bslstl_map_test1': !PRIVATE!
327/// Provide support for the `bslstl_map.t.cpp` test driver.
328///
329/// 'bslstl_map_test2': !PRIVATE!
330/// Provide support for the `bslstl_map.t.cpp` test driver.
331///
332/// 'bslstl_map_test3': !PRIVATE!
333/// Provide support for the `bslstl_map.t.cpp` test driver.
334///
335/// @ref bslstl_mapcomparator :
336/// Provide a comparator for `TreeNode` objects and a lookup key.
337///
338/// @ref bslstl_monostate :
339/// Provide a default constructible alternative for `bsl::variant`.
340///
341/// @ref bslstl_multimap :
342/// Provide an STL-compliant multimap class.
343///
344/// 'bslstl_multimap_cpp03': !PRIVATE!
345/// Provide C++03 implementation for bslstl_multimap.h
346///
347/// 'bslstl_multimap_test': !PRIVATE!
348/// Provide support for the `bslstl_multimap.t.cpp` test driver.
349///
350/// @ref bslstl_multiset :
351/// Provide an STL-compliant multiset class.
352///
353/// 'bslstl_multiset_cpp03': !PRIVATE!
354/// Provide C++03 implementation for bslstl_multiset.h
355///
356/// 'bslstl_multiset_test': !PRIVATE!
357/// Provide support for the `bslstl_multiset.t.cpp` test driver.
358///
359/// @ref bslstl_optional :
360/// Provide a standard-compliant allocator aware optional type.
361///
362/// 'bslstl_optional_cpp03': !PRIVATE!
363/// Provide C++03 implementation for bslstl_optional.h
364///
365/// @ref bslstl_ostream :
366/// Provide aliases and implementations matching standard <ostream>.
367///
368/// @ref bslstl_ostringstream :
369/// Provide a C++03-compatible `ostringstream` class.
370///
371/// @ref bslstl_osyncstream :
372/// Provide a C++20-compatible @ref basic_osyncstream class template.
373///
374/// @ref bslstl_ownerequal :
375/// Provide an ownership comparison for shared and weak pointers.
376///
377/// @ref bslstl_ownerhash :
378/// Provide an ownership hash functor for shared and weak pointers.
379///
380/// @ref bslstl_ownerless :
381/// Provide an ordering for shared and weak pointers.
382///
383/// @ref bslstl_pair :
384/// Provide a simple `struct` with two members that may use allocators.
385///
386/// @ref bslstl_priorityqueue :
387/// Provide container adapter class template @ref priority_queue .
388///
389/// 'bslstl_priorityqueue_cpp03': !PRIVATE!
390/// Provide C++03 implementation for bslstl_priorityqueue.h
391///
392/// @ref bslstl_queue :
393/// Provide container adapter class template `queue`.
394///
395/// 'bslstl_queue_cpp03': !PRIVATE!
396/// Provide C++03 implementation for bslstl_queue.h
397///
398/// @ref bslstl_randomaccessiterator :
399/// Provide a template to create STL-compliant random access iterators.
400///
401/// @ref bslstl_ratio :
402/// Provide functionality of the corresponding C++ Standard header.
403///
404/// @ref bslstl_referencewrapper :
405/// Provide copyable, assignable object wrapper for references.
406///
407/// 'bslstl_set':
408/// Provide an STL-compliant set class.
409///
410/// 'bslstl_set_cpp03': !PRIVATE!
411/// Provide C++03 implementation for bslstl_set.h
412///
413/// 'bslstl_set_test': !PRIVATE!
414/// Provide support for the `bslstl_set.t.cpp` test driver.
415///
416/// @ref bslstl_setcomparator :
417/// Provide a comparator for `TreeNode` objects and a lookup key.
418///
419/// @ref bslstl_sharedptr :
420/// Provide a generic reference-counted shared pointer wrapper.
421///
422/// 'bslstl_sharedptr_cpp03': !PRIVATE!
423/// Provide C++03 implementation for bslstl_sharedptr.h
424///
425/// @ref bslstl_sharedptrallocateinplacerep :
426/// Provide an in-place implementation of `bslma::SharedPtrRep`.
427///
428/// @ref bslstl_sharedptrallocateoutofplacerep :
429/// Provide an out-of-place implementation of `bslma::SharedPtrRep`.
430///
431/// @ref bslstl_simplepool :
432/// Provide efficient allocation of memory blocks for a specific type.
433///
434/// @ref bslstl_span :
435/// Provide a (mostly) standard-compliant `span` class template.
436///
437/// @ref bslstl_stack :
438/// Provide an STL-compliant stack class.
439///
440/// 'bslstl_stack_cpp03': !PRIVATE!
441/// Provide C++03 implementation for bslstl_stack.h
442///
443/// @ref bslstl_stdexceptutil :
444/// Provide a utility to throw standard exceptions.
445///
446/// @ref bslstl_stopstate :
447/// Provide a stop state for `std`-compliant stop tokens.
448///
449/// @ref bslstl_stoptoken :
450/// Provide an allocator-aware standard-compliant @ref stop_source type.
451///
452/// @ref bslstl_string :
453/// Provide a standard-compliant @ref basic_string class template.
454///
455/// 'bslstl_string_test': !PRIVATE!
456/// Provide support for the `bslstl_string.t.cpp` test driver.
457///
458/// @ref bslstl_stringbuf :
459/// Provide a C++03-compatible `stringbuf` class.
460///
461/// @ref bslstl_stringref :
462/// Provide a reference to a `const` string.
463///
464/// @ref bslstl_stringrefdata :
465/// Provide a base class for `bslstl::StringRef`.
466///
467/// @ref bslstl_stringstream :
468/// Provide a C++03-compatible `stringstream` class.
469///
470/// @ref bslstl_stringview :
471/// Provide a standard-compliant `basic_string_view` class template.
472///
473/// @ref bslstl_syncbuf :
474/// Provide a C++20-compatible @ref basic_syncbuf class template.
475///
476/// @ref bslstl_syncbufbase :
477/// Provide an allocator-independent base-class for @ref basic_syncbuf .
478///
479/// @ref bslstl_systemerror :
480/// Provide a standard compliant @ref system_error class.
481///
482/// @ref bslstl_treeiterator :
483/// Provide an STL compliant iterator for a tree of `TreeNode` objects.
484///
485/// @ref bslstl_treenode :
486/// Provide a POD-like tree node type holding a parameterized value.
487///
488/// @ref bslstl_treenodepool :
489/// Provide efficient creation of nodes used in tree-based container.
490///
491/// 'bslstl_treenodepool_cpp03': !PRIVATE!
492/// Provide C++03 implementation for bslstl_treenodepool.h
493///
494/// @ref bslstl_typeindex :
495/// Provide an value-semantic type to represent @ref type_info objects.
496///
497/// @ref bslstl_unorderedmap :
498/// Provide an STL-compliant `unordered_map` container.
499///
500/// 'bslstl_unorderedmap_cpp03': !PRIVATE!
501/// Provide C++03 implementation for bslstl_unorderedmap.h
502///
503/// 'bslstl_unorderedmap_test': !PRIVATE!
504/// Provide support for the `bslstl_unorderedmap.t.cpp` test driver.
505///
506/// @ref bslstl_unorderedmapkeyconfiguration :
507/// Provide a class template to extract keys as the `first` attribute.
508///
509/// @ref bslstl_unorderedmultimap :
510/// Provide an STL-compliant @ref unordered_multimap container.
511///
512/// 'bslstl_unorderedmultimap_cpp03': !PRIVATE!
513/// Provide C++03 implementation for bslstl_unorderedmultimap.h
514///
515/// 'bslstl_unorderedmultimap_test': !PRIVATE!
516/// Provide support for the `bslstl_unorderedmultimap.t.cpp` test driver.
517///
518/// @ref bslstl_unorderedmultiset :
519/// Provide an STL-compliant @ref unordered_multiset container.
520///
521/// 'bslstl_unorderedmultiset_cpp03': !PRIVATE!
522/// Provide C++03 implementation for bslstl_unorderedmultiset.h
523///
524/// 'bslstl_unorderedmultiset_test': !PRIVATE!
525/// Provide support for the `bslstl_unorderedmultiset.t.cpp` test driver.
526///
527/// @ref bslstl_unorderedset :
528/// Provide an STL-compliant `unordered_set` container.
529///
530/// 'bslstl_unorderedset_cpp03': !PRIVATE!
531/// Provide C++03 implementation for bslstl_unorderedset.h
532///
533/// 'bslstl_unorderedset_test': !PRIVATE!
534/// Provide support for the `bslstl_unorderedset.t.cpp` test driver.
535///
536/// @ref bslstl_unorderedsetkeyconfiguration :
537/// Provide a configuration class to use a whole object as its own key.
538///
539/// @ref bslstl_utility :
540/// Provide implementations for utilities not in the system library.
541///
542/// @ref bslstl_variant :
543/// Provide a standard-compliant allocator aware variant type.
544///
545/// 'bslstl_variant_cpp03': !PRIVATE!
546/// Provide C++03 implementation for bslstl_variant.h
547///
548/// @ref bslstl_vector :
549/// Provide an STL-compliant vector class.
550///
551/// 'bslstl_vector_cpp03': !PRIVATE!
552/// Provide C++03 implementation for bslstl_vector.h
553///
554/// @}
555/** @} */