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