File: index.rst

package info (click to toggle)
mdds 3.1.0-3
  • links: PTS
  • area: main
  • in suites: forky, sid
  • size: 6,064 kB
  • sloc: cpp: 20,809; sh: 1,369; makefile: 624; python: 603
file content (28 lines) | stat: -rw-r--r-- 913 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
.. highlight:: cpp


Trie Maps
=========

The :cpp:class:`~mdds::trie_map` class is an associative container that stores
multiple key-value pairs similar to ``std::map``, but the key-value pairs are
stored in a `trie structure <https://en.wikipedia.org/wiki/Trie>`_ to optimize
for prefix searches.

Another data structure similar to :cpp:class:`~mdds::trie_map` is
:cpp:class:`~mdds::packed_trie_map`, which provides search API nearly identical
to that of :cpp:class:`~mdds::trie_map` but is immutable once created.  Instead,
:cpp:class:`~mdds::packed_trie_map` stores all of its content in a contiguous
memory region to improve memory locality, and also supports serialization of its
state to an external buffer.

.. toctree::
   :maxdepth: 1

   populate-trie-map.rst
   pack-trie-map.rst
   direct-packed-trie-map.rst
   save-load-packed-trie-map.rst
   save-load-packed-trie-map-custom-value.rst
   api.rst