__GNU_PBDS::TRIE(3)
π __gnu_pbds::trie< Key, Mapped, _ATraits, Tag, Node_Update, _Alloc > π
okay so bestie, welcome to the Library Functions Manual for libstdc++ β this one's a whole vibe, it's the trie container from __gnu_pbds, and yes she's fancy π
β¨ NAME β¨
__gnu_pbds::trie< Key, Mapped, _ATraits, Tag, Node_Update, _Alloc > β the trie-based container, no cap π
πΈ SYNOPSIS πΈ
#include <assoc_container.hpp>
Inherits __gnu_pbds::basic_branch< Key, Mapped, Tag, Node_Update, Policy_Tl, _Alloc > β so she's got that basic_branch bloodline, iconic π
π Public Types
access_traitsβ atypedeffor_ATraits, aka the element access traits type β¨node_updateβ atypedefforNode_Update
π¦ Public Member Functions
trie(const access_traits &t)β constructor that takes some policy objects.r_access_traitswill be copied by the_ATraitsobject of the container object. π«Άtrie(const trie &other)β the copy constructor, she's copying the whole girl πtemplate<typename It> trie(It first, It last)β constructor taking__iteratorsto a range ofvalue_types. Thevalue_typesbetweenfirst_itandlast_itwill be inserted into the container object.template<typename It> trie(It first, It last, const access_traits &t)β constructor taking__iteratorsto a range ofvalue_typesand some policy objects. Thevalue_typesbetweenfirst_itandlast_itwill be inserted into the container object. β¨trie & operator=(const trie &other)β assignment, she's swapping her whole personality πvoid swap(trie &other)β swaps withother, trading places like it's nothing π
π Detailed Description π
template<typename Key, typename Mapped, typename _ATraits = typename
detail::default_trie_access_traits<Key>::type, typename Tag =
pat_trie_tag, template< typename Node_CItr, typename Node_Itr, typename
_ATraits_, typename _Alloc_ > class Node_Update = null_node_update,
typename _Alloc = std::allocator<char>>
class __gnu_pbds::trie< Key, Mapped, _ATraits, Tag, Node_Update, _Alloc >
"A trie-based container." β that's the whole pitch, periodt π
π Template Parameters
Keyβ the Key type.Mappedβ the Map type._ATraitsβ the Element access traits.Tagβ the instantiating data structure type, seecontainer_tag.Node_Updateβ updates trie internal-nodes, restores invariants when invalidated. XXX Seedesign::tree-based-containersnodeinvariants._Allocβ the Allocator type.
Base tag choice is pat_trie_tag.
Base is basic_branch. π«Ά
π§ Member Typedef Documentation π§
template<typename Key, typename Mapped, typename _ATraits = typename
detail::default_trie_access_traits<Key>::type, typename Tag =
pat_trie_tag, template< typename Node_CItr, typename Node_Itr, typename
_ATraits_, typename _Alloc_ > class Node_Update = null_node_update,
typename _Alloc = std::allocator<char>>
typedef _ATraits __gnu_pbds::trie< Key, Mapped, _ATraits, Tag, Node_Update,
_Alloc >::access_traits
access_traits is just the element access traits type. That's it, that's the girl π
π Constructor & Destructor Documentation π
πΈ trie(const access_traits &t) β [inline]
template<typename Key, typename Mapped, typename _ATraits = typename
detail::default_trie_access_traits<Key>::type, typename Tag =
pat_trie_tag, template< typename Node_CItr, typename Node_Itr, typename
_ATraits_, typename _Alloc_ > class Node_Update = null_node_update,
typename _Alloc = std::allocator<char>>
__gnu_pbds::trie< Key, Mapped, _ATraits, Tag, Node_Update, _Alloc >::trie
(const access_traits & t)
Constructor taking some policy objects. r_access_traits will be copied by the _ATraits object of the container object. she's taking notes from her policy besties π
π¦ trie(It first, It last) β [inline]
template<typename Key, typename Mapped, typename _ATraits = typename
detail::default_trie_access_traits<Key>::type, typename Tag =
pat_trie_tag, template< typename Node_CItr, typename Node_Itr, typename
_ATraits_, typename _Alloc_ > class Node_Update = null_node_update,
typename _Alloc = std::allocator<char>>
template<typename It>
__gnu_pbds::trie< Key, Mapped, _ATraits, Tag, Node_Update, _Alloc >::trie
(It first, It last)
Constructor taking __iterators to a range of value_types. The value_types between first_it and last_it will be inserted into the container object. π
β¨ trie(It first, It last, const access_traits &t) β [inline]
template<typename Key, typename Mapped, typename _ATraits = typename
detail::default_trie_access_traits<Key>::type, typename Tag =
pat_trie_tag, template< typename Node_CItr, typename Node_Itr, typename
_ATraits_, typename _Alloc_ > class Node_Update = null_node_update,
typename _Alloc = std::allocator<char>>
template<typename It>
__gnu_pbds::trie< Key, Mapped, _ATraits, Tag, Node_Update, _Alloc >::trie
(It first, It last, const access_traits & t)
Constructor taking __iterators to a range of value_types and some policy objects. The value_types between first_it and last_it will be inserted into the container object. both at once?? she's multi-tasking, we love to see it π
π Author π
Generated automatically by Doxygen for libstdc++ from the source code. so like, no human wrote this, it's giving robot autopilot π€β¨
fr fr bestie, this page came straight out of the Library Functions Manual for libstdc++ β mwah, no notes, obsessed π«Άππ
π¦ where this page comes from
- arch rolling: gcc 16.2.1+r23+gd564253eb6c8-1 Β· GPL-3.0-or-later WITH GCC-exception-3.1 AND GFDL-1.3-or-later
- fedora 44: libstdc++-docs 16.0.1-0.10.fc44 Β· GPL-3.0-or-later AND LGPL-3.0-or-later AND (GPL-3.0-or-later WITH GCC-exception-3.1) AND (GPL-3.0-or-later WITH Texinfo-exception) AND (LGPL-2.1-or-later WITH GCC-exception-2.0) AND (GPL-2.0-or-later WITH GCC-exception-2.0) AND (GPL-2.0-or-later WITH GNU-compiler-exception) AND BSL-1.0 AND GFDL-1.3-or-later AND Linux-man-pages-copyleft-2-para AND SunPro AND BSD-1-Clause AND BSD-2-Clause AND BSD-2-Clause-Views AND BSD-3-Clause AND BSD-4-Clause AND BSD-Source-Code AND Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 WITH LLVM-Exception) AND ZPL-2.1 AND ISC AND LicenseRef-Fedora-Public-Domain AND HP-1986 AND curl AND Martin-Birgmeier AND HPND-Markus-Kuhn AND dtoa AND SMLNJ AND AMD-newlib AND OAR AND HPND-merchantability-variant AND HPND-Intel
- fedora 44: libstdc++-docs 16.2.1-2.fc44
- fedora 44: libstdc++-docs 16.2.1-3.fc44 Β· GPL-3.0-or-later AND LGPL-3.0-or-later AND (GPL-3.0-or-later WITH GCC-exception-3.1) AND (GPL-3.0-or-later WITH Texinfo-exception) AND (LGPL-2.1-or-later WITH GCC-exception-2.0) AND (GPL-2.0-or-later WITH GCC-exception-2.0) AND (GPL-2.0-or-later WITH GNU-compiler-exception) AND BSL-1.0 AND GFDL-1.3-or-later AND Linux-man-pages-copyleft-2-para AND SunPro AND BSD-1-Clause AND BSD-2-Clause AND BSD-2-Clause-Views AND BSD-3-Clause AND BSD-4-Clause AND BSD-Source-Code AND Zlib AND MIT AND Apache-2.0 AND (Apache-2.0 WITH LLVM-Exception) AND ZPL-2.1 AND ISC AND LicenseRef-Fedora-Public-Domain AND HP-1986 AND curl AND Martin-Birgmeier AND HPND-Markus-Kuhn AND dtoa AND SMLNJ AND AMD-newlib AND OAR AND HPND-merchantability-variant AND HPND-Intel
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms