AIToolbox
A library that offers tools for AI problem solving.
TypeTraits.hpp
Go to the documentation of this file.
1 #ifndef AI_TOOLBOX_FACTORED_BANDIT_TYPE_TRAITS_HEADER_FILE
2 #define AI_TOOLBOX_FACTORED_BANDIT_TYPE_TRAITS_HEADER_FILE
3 
4 #include <ranges>
5 
7 
14  template <typename QR>
15  concept IsQFunctionRule = requires (const QR qr) {
16  { qr.action } -> std::convertible_to<PartialAction>;
17  { qr.value } -> std::convertible_to<double>;
18  };
19 
23  template <typename T>
24  concept QFRuleRange = std::ranges::range<T> && IsQFunctionRule<std::ranges::range_value_t<T>>;
25 }
26 
27 #endif
Types.hpp
AIToolbox::Factored::Bandit::QFRuleRange
concept QFRuleRange
This concept represents a range of QFunctionRules.
Definition: TypeTraits.hpp:24
AIToolbox::Factored::Bandit::IsQFunctionRule
concept IsQFunctionRule
This concept models the interface for a QFunctionRule.
Definition: TypeTraits.hpp:15
AIToolbox::Factored::Bandit
Definition: GraphUtils.hpp:12