-
-
Notifications
You must be signed in to change notification settings - Fork 89
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use battle-tested PATRICIA tree (WIP)
- Loading branch information
Showing
2 changed files
with
1,237 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
// _ _____ __________ | ||
// | | / / _ | / __/_ __/ Visibility | ||
// | |/ / __ |_\ \ / / Across | ||
// |___/_/ |_/___/ /_/ Space and Time | ||
// | ||
// SPDX-FileCopyrightText: (c) 2024 The Tenzir Contributors | ||
// SPDX-License-Identifier: BSD-3-Clause | ||
|
||
#pragma once | ||
|
||
namespace tenzir::detail { | ||
|
||
/// A PATRICIA trie or *tree* (as Knuth calls it) is trie with radix of two. | ||
/// Nodes exist to identify the bits that distinguish the keys. Each node is | ||
/// exactly two children, like a binary tree, and therefore the number of nodes | ||
/// is the number of keys. | ||
class patricia_tree { | ||
public: | ||
patricia_tree() = default; | ||
|
||
private: | ||
class impl; | ||
std::unique_ptr<impl> impl_; | ||
}; | ||
|
||
} // namespace tenzir::detail |
Oops, something went wrong.