template<typename T, typename Key>
requires { typename T::Node; } &&
requires(
T & t,
T &
t2,
const T &
ct,
typename T::Node * p, const Key & key)
{
{ t.getRoot() } -> std::convertible_to<typename T::Node *>;
{ t.search(key) } -> std::convertible_to<typename T::Node *>;
{ t.search_or_insert(p) } -> std::convertible_to<typename T::Node *>;
{ t.insert_dup(p) } -> std::convertible_to<typename T::Node *>;
{ t.remove(key) } -> std::convertible_to<typename T::Node *>;
{
ct.verify() } -> std::convertible_to<bool>;
{ t.get_compare() };
requires (!
requires {
ct.getRoot(); } ||
requires
{
{
ct.getRoot() } -> std::convertible_to<const typename T::Node *>;
});
requires (!
requires {
ct.search(key); } ||
requires
{
{
ct.search(key) } -> std::convertible_to<const typename T::Node *>;
});
}
Concept for BST tree policies used by DynSetTree.
Divide_Conquer_DP_Result< Cost > divide_and_conquer_partition_dp(const size_t groups, const size_t n, Transition_Cost_Fn transition_cost, const Cost inf=dp_optimization_detail::default_inf< Cost >())
Optimize partition DP using divide-and-conquer optimization.
std::decay_t< typename HeadC::Item_Type > T
Concept for BST tree policies used by DynSetTree.
Checks that an instantiated tree type T = Tree<Key, Compare> exposes the minimal interface required by DynSetTree: a Node type alias and the core operations getRoot, search, search_or_insert, insert_dup, remove, verify, swap, and get_compare.
Optional operations (join, select, position, …) are NOT checked here because not every tree type supports them.
- Template Parameters
-
| T | the fully instantiated tree type, e.g. Avl_Tree<int>. |
| Key | the key type stored in the tree. |
Definition at line 116 of file ah-concepts.H.