#include <uhd/experts/expert_factory.hpp>
Static Public Member Functions | |
static expert_container::sptr | create_container (const std::string &name) |
template<typename data_t > | |
static void | add_data_node (expert_container::sptr container, const std::string &name, const data_t &init_val, const auto_resolve_mode_t mode=AUTO_RESOLVE_OFF) |
template<typename data_t > | |
static property< data_t > & | add_prop_node (expert_container::sptr container, property_tree::sptr subtree, const fs_path &path, const std::string &name, const data_t &init_val, const auto_resolve_mode_t mode=AUTO_RESOLVE_OFF) |
template<typename data_t > | |
static property< data_t > & | add_prop_node (expert_container::sptr container, property_tree::sptr subtree, const fs_path &path, const data_t &init_val, const auto_resolve_mode_t mode=AUTO_RESOLVE_OFF) |
template<typename data_t > | |
static property< data_t > & | add_dual_prop_node (expert_container::sptr container, property_tree::sptr subtree, const fs_path &path, const std::string &desired_name, const std::string &coerced_name, const data_t &init_val, const auto_resolve_mode_t mode=AUTO_RESOLVE_OFF) |
template<typename data_t > | |
static property< data_t > & | add_dual_prop_node (expert_container::sptr container, property_tree::sptr subtree, const fs_path &path, const data_t &init_val, const auto_resolve_mode_t mode=AUTO_RESOLVE_OFF) |
template<typename worker_t > | |
static void | add_worker_node (expert_container::sptr container) |
template<typename worker_t , typename arg1_t > | |
static void | add_worker_node (expert_container::sptr container, arg1_t const &arg1) |
template<typename worker_t , typename arg1_t , typename arg2_t > | |
static void | add_worker_node (expert_container::sptr container, arg1_t const &arg1, arg2_t const &arg2) |
template<typename worker_t , typename arg1_t , typename arg2_t , typename arg3_t > | |
static void | add_worker_node (expert_container::sptr container, arg1_t const &arg1, arg2_t const &arg2, arg3_t const &arg3) |
template<typename worker_t , typename arg1_t , typename arg2_t , typename arg3_t , typename arg4_t > | |
static void | add_worker_node (expert_container::sptr container, arg1_t const &arg1, arg2_t const &arg2, arg3_t const &arg3, arg4_t const &arg4) |
template<typename worker_t , typename arg1_t , typename arg2_t , typename arg3_t , typename arg4_t , typename arg5_t > | |
static void | add_worker_node (expert_container::sptr container, arg1_t const &arg1, arg2_t const &arg2, arg3_t const &arg3, arg4_t const &arg4, arg5_t const &arg5) |
template<typename worker_t , typename arg1_t , typename arg2_t , typename arg3_t , typename arg4_t , typename arg5_t , typename arg6_t > | |
static void | add_worker_node (expert_container::sptr container, arg1_t const &arg1, arg2_t const &arg2, arg3_t const &arg3, arg4_t const &arg4, arg5_t const &arg5, arg6_t const &arg6) |
template<typename worker_t , typename arg1_t , typename arg2_t , typename arg3_t , typename arg4_t , typename arg5_t , typename arg6_t , typename arg7_t > | |
static void | add_worker_node (expert_container::sptr container, arg1_t const &arg1, arg2_t const &arg2, arg3_t const &arg3, arg4_t const &arg4, arg5_t const &arg5, arg6_t const &arg6, arg7_t const &arg7) |
template<typename worker_t , typename arg1_t , typename arg2_t , typename arg3_t , typename arg4_t , typename arg5_t , typename arg6_t , typename arg7_t , typename arg8_t > | |
static void | add_worker_node (expert_container::sptr container, arg1_t const &arg1, arg2_t const &arg2, arg3_t const &arg3, arg4_t const &arg4, arg5_t const &arg5, arg6_t const &arg6, arg7_t const &arg7, arg7_t const &arg8) |
expert_factory is a friend of expert_container and handles all operations to create and change the structure of the an expert container. The expert_factory allocates storage for the nodes in the expert_container and passes allocated objects to the container using private APIs. The expert_container instance owns all data and workernodes and is responsible for releasing their storage on destruction.
|
inlinestatic |
Add a data node to the expert graph.
container | A shared pointer to the container to add the node to |
name | The name of the data node |
init_val | The initial value of the data node |
mode | The auto resolve mode |
Requirements for data_t
|
inlinestatic |
Add a dual expert property to a property tree AND an expert graph. A dual property is a desired and coerced value pair
container | A shared pointer to the expert container to add the node to |
subtree | A shared pointer to subtree to add the property to |
path | The path of the property in the subtree |
desired_name | The name of the desired data node in the expert graph |
coerced_name | The name of the coerced data node in the expert graph |
init_val | The initial value of both the data nodes |
mode | The auto resolve mode |
Requirements for data_t
|
inlinestatic |
Add a dual expert property to a property tree AND an expert graph. A dual property is a desired and coerced value pair The property is registered with path/desired as the desired node name and path/coerced as the coerced node name
container | A shared pointer to the expert container to add the node to |
subtree | A shared pointer to subtree to add the property to |
path | The path of the property in the subtree |
init_val | The initial value of both the data nodes |
mode | The auto resolve mode |
|
inlinestatic |
Add a expert property to a property tree AND an expert graph
The underlying property can be used like any other property tree property, including setting a coercer through set_coercer(). However, this means that the coercion is happening outside of the expert framework. This is primarily useful for tiny coercions (e.g., we accept both upper and lower case values, but only want lower case downstream) for which we don't want to bother with a full expert, or for which we don't want to trigger resolution at all (if mode is set to AUTO_RESOLVE_OFF). For more full-fledged coercion, prefer add_dual_prop_node(). This will properly engage the expert graph.
container | A shared pointer to the expert container to add the node to |
subtree | A shared pointer to subtree to add the property to |
path | The path of the property in the subtree |
name | The name of the data node in the expert graph |
init_val | The initial value of the data node |
mode | The auto resolve mode |
Requirements for data_t
|
inlinestatic |
Add a expert property to a property tree AND an expert graph. The property is registered with the path as the identifier for both the property subtree and the expert container
container | A shared pointer to the expert container to add the node to |
subtree | A shared pointer to subtree to add the property to |
path | The path of the property in the subtree |
init_val | The initial value of the data node |
mode | The auto resolve mode |
|
inlinestatic |
Add a worker node to the expert graph. The expert_container owns and manages storage for the worker
worker_t | Data type of the worker class |
container | A shared pointer to the container to add the node to |
|
inlinestatic |
Add a worker node to the expert graph. The expert_container owns and manages storage for the worker
worker_t | Data type of the worker class |
arg1_t | Data type of the first argument to the constructor |
... | |
argN_t | Data type of the Nth argument to the constructor |
container | A shared pointer to the container to add the node to |
arg1 | First arg to ctor |
... |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
inlinestatic |
|
static |
Creates an empty instance of expert_container with the specified name.
name | Name of the container |