|
DUNE-DAQ
DUNE Trigger and Data Acquisition software
|
#include <gtool.hpp>
Classes | |
| struct | vertex_label |
Public Types | |
| typedef boost::adjacency_list< boost::vecS, boost::vecS, boost::bidirectionalS, vertex_label > | t_graph |
| typedef boost::graph_traits< t_graph >::edge_descriptor | t_edge |
| typedef boost::graph_traits< t_graph >::vertex_descriptor | t_vertex |
| typedef std::map< std::string, t_vertex > | t_registry |
| typedef std::pair< bool, boost::graph_traits< gtool::t_graph >::vertex_iterator > | t_lookup_ret |
Public Member Functions | |
| gtool (std::string const &rl, dbinfo dbtype) | |
| template<typename ALGO> | |
| int | load_and_run (ALGO const &) |
| t_graph const & | getgraph () const |
Static Public Member Functions | |
| static t_vertex | add_object_and_friends (t_graph &, tref const &, t_registry ®istry) |
| static t_vertex | add_object (t_graph &g, tref const &o, bool uniqueness=true) |
| static t_vertex | add_object (t_graph &g, tref const &o, t_registry ®istry) |
| static t_lookup_ret | lookup (t_graph const &g, vertex_label const &l) |
Private Types | |
| typedef std::vector< tref > | t_objects |
Private Member Functions | |
| void | load_all () |
| void | load_all_class_objects (std::string const &cname) |
| void | create_graph () |
Private Attributes | |
| t_graph | this_graph |
| t_objects | this_all_objects |
| t_registry | already_processed |
| std::string | this_src |
| typedef boost::graph_traits<t_graph>::edge_descriptor dbe::tool::graph::gtool::t_edge |
| typedef boost::adjacency_list<boost::vecS, boost::vecS, boost::bidirectionalS, vertex_label> dbe::tool::graph::gtool::t_graph |
| typedef std::pair<bool, boost::graph_traits<gtool::t_graph>::vertex_iterator> dbe::tool::graph::gtool::t_lookup_ret |
|
private |
| typedef std::map<std::string, t_vertex> dbe::tool::graph::gtool::t_registry |
| typedef boost::graph_traits<t_graph>::vertex_descriptor dbe::tool::graph::gtool::t_vertex |
| dbe::tool::graph::gtool::gtool | ( | std::string const & | rl, |
| dbinfo | dbtype ) |
Construct gtool object from string a resource location and db information type Resulting object loads a database from the resource location of the designated type
| fn | is a string designating the resource location of the database |
| dbtype | is the type (dbinfo) of the database access method (e.g. oks, rdb ... ) |
Definition at line 37 of file gtool.cpp.
|
static |
Add an object to a graph without its relations
| g | is a reference to the graph |
| o | is a reference to the object |
| uniqueness | only add the object if there is no vertex already abstracting it |
Definition at line 118 of file gtool.cpp.
|
static |
Add an object to a graph without its relations if it is not found in the provided registry
| g | is a reference to the graph |
| o | is a reference to the object |
| registry | is a set of tags already present , and implies adding the object only if its tag is not in the registry ( speed up lookups ) |
Definition at line 146 of file gtool.cpp.
|
static |
Add an object to a graph along with all connected objects through any relation
| a | reference to the graph |
| a | registry of tags of objects already present in the graph |
Definition at line 166 of file gtool.cpp.
|
private |
Definition at line 105 of file gtool.cpp.
| gtool::t_graph const & dbe::tool::graph::gtool::getgraph | ( | ) | const |
Retrieve the graph as it currently is
|
private |
Definition at line 73 of file gtool.cpp.
|
private |
Definition at line 89 of file gtool.cpp.
|
inline |
|
static |
Lookup a vector in the graph , runs in O(N) worst case
| g | is the graph |
| l | is the graph label |
Definition at line 188 of file gtool.cpp.
|
private |
|
private |