8 #ifndef GUI_GRAPH_CONTROLLER_H_
9 #define GUI_GRAPH_CONTROLLER_H_
12 #include <QStringList>
15 #include <QStandardItemModel>
28 #include "linkler_diff.h"
29 #include "xmlparser.h"
30 #include "filterparser.h"
31 #include "graph_exporter.h"
34 #include "hide_action.h"
35 #include "edge_type_filter.h"
36 #include "dependency_degree_filter.h"
37 #include "run_block_filter.h"
38 #include "noop_action.h"
39 #include "graph_filter.h"
40 #include "node_exclusion_filter.h"
41 #include "diff_filter.h"
42 #include "regex_filter.h"
43 #include "graph_filter_list.h"
44 #include "set_property_action.h"
45 #include "swu_graph_builder.h"
46 #include "module_graph_builder.h"
47 #include "graph_model.h"
48 #include "module_graph_model.h"
49 #include "swu_graph_model.h"
50 #include "filter_model.h"
170 bool has_item(std::string item_name);
300 void rebuild_graph(
bool lay =
true);
311 void graph_item(std::pair<std::string, bool> node);
340 void insert_filter(std::string name,
347 std::map<std::string, std::string> params,
353 void update_filters();
359 bool contract_recursively(std::string item_name, std::string search_name);
368 void search(std::string search_term, std::string search_type);
378 bool expand_item(std::string expand_item_,
bool last,
bool emit =
true,
bool update_focus =
false,
bool recursively =
false);
387 bool contract_item(std::string item_name,
bool last,
bool emit =
true);
436 std::map<std::string,std::string> params,
459 std::map<std::string,std::string> params,
482 std::map<std::string,std::string> params,
505 std::map<std::string,std::string> params,
524 void graphChanged(std::string focus_node =
"",
bool reset_zoom =
false);
526 void unknownItem(std::string item_name);
546 void postFilterModelChanged();
550 void preFilterModelChanged();
567 std::string focus_item_;
571 std::set< std::pair<std::string, bool> > expanded_items_;
580 std::string layout_type_;
598 std::vector<std::string> previously_focused_items_;
void reset_all_post_filters()
Definition: main_controller.cc:658
Definition: swu_graph_builder.h:22
void import_filters(std::string file_path, bool clear=true)
Definition: main_controller.cc:752
void undo_focused()
Definition: main_controller.cc:329
void remove_post_filter(std::string filter_name, bool last=true)
Definition: main_controller.cc:476
void graphChanged(std::string focus_node="", bool reset_zoom=false)
Definition: graph_builder.h:4
void insert_post_filter(std::string name, std::string type, bool hide, bool inverted_b, bool enabled, std::string color, std::string opacity, std::map< std::string, std::string > params, bool last)
Definition: main_controller.cc:510
QStringList get_run_blocks()
Definition: main_controller.cc:161
bool has_item(std::string item_name)
Definition: main_controller.cc:291
void reinclude_all_excluded_nodes()
Definition: main_controller.cc:324
GraphModel * emptyModel()
Definition: main_controller.cc:445
bool expand_item(std::string expand_item_, bool last, bool emit=true, bool update_focus=false, bool recursively=false)
Definition: main_controller.cc:172
void export_filters(std::string file_path)
Definition: main_controller.cc:781
GraphFilterList< GraphType > & post_filters()
Definition: main_controller.h:279
void remove_pre_filter(std::string filter_name, bool last=true)
Definition: main_controller.cc:469
void export_conditional_formattings(std::string file_path)
Definition: main_controller.cc:810
QStandardItemModel * pre_filter_model()
Definition: main_controller.cc:819
bool contract_item(std::string item_name, bool last, bool emit=true)
Contract an item, that is remove it from expanded items.
Definition: main_controller.cc:207
std::vector< std::string > excluded_nodes()
Definition: main_controller.cc:735
GraphType::node_value_type item(std::string name)
Definition: main_controller.cc:687
int graph_width() const
Get graph width.
Definition: main_controller.cc:681
void duplicateFilterName(std::string filter_name)
void invalidFilterName(std::string filter_name)
void load_diff_from_xml(std::string file_name)
Definition: main_controller.cc:79
void insert_pre_filter(std::string name, std::string type, bool hide, bool inverted_b, bool enabled, std::string color, std::string opacity, std::map< std::string, std::string > params, bool last)
Definition: main_controller.cc:490
void set_layout_type(std::string layout_type, bool relayout=true)
Definition: main_controller.cc:703
bool has_pre_layout_filters()
Definition: main_controller.cc:665
QStandardItemModel * post_filter_model()
Definition: main_controller.cc:815
void import_conditional_formattings(std::string file_path, bool clear=true)
Definition: main_controller.cc:786
bool has_post_layout_filters()
Check if it has pre layout filters.
Definition: main_controller.cc:670
GraphModel * graphModel()
Definition: main_controller.cc:407
void search(std::string search_term, std::string search_type)
Definition: main_controller.cc:134
void add_to_focused(std::string name)
Definition: main_controller.cc:306
void update_post_filter(std::string name, std::string type, bool hide, bool inverted_b, bool enabled, std::string color, std::string opacity, std::map< std::string, std::string > params, bool last)
Definition: main_controller.cc:636
Definition: graph_filter_list.h:16
Definition: linkler_diff.h:14
bool save_to_graphviz(std::string file_name)
Definition: main_controller.cc:120
MainController()
Definition: main_controller.cc:3
bool is_expanded(std::string item_name)
Definition: main_controller.cc:285
void exclude_item(std::string item_name, bool last)
Definition: main_controller.cc:459
Definition: graph_properties.h:7
GraphModel * treeModel(bool dependents, bool dependencies)
Definition: main_controller.cc:424
virtual ~MainController()
Definition: main_controller.cc:27
GraphFilterList< GraphType > & pre_filters()
Definition: main_controller.h:273
int graph_height() const
Get graph height.
Definition: main_controller.cc:684
void set_dependencies(bool dependencies)
Definition: main_controller.cc:697
unsigned int num_nodes()
Definition: main_controller.cc:674
void reinclude_excluded_node(std::string name)
Definition: main_controller.cc:319
Definition: main_controller.h:54
GraphModel * fullModel()
Definition: main_controller.cc:451
Definition: swu_graph_model.h:24
void set_dependents(bool dependents)
Definition: main_controller.cc:691
bool was_any_node_focused()
Definition: main_controller.cc:748
void set_linkler(Linkler *linkler, bool free=true)
Definition: main_controller.cc:711
void load_from_xml(std::string file_name)
Definition: main_controller.cc:45
SWUGraphBuilder GraphBuilder
Typedefs to make the application more generalized.
Definition: main_controller.h:70
void reset_all_pre_filters()
Definition: main_controller.cc:650
std::string focus_item() const
Definition: main_controller.cc:678
void update_pre_filter(std::string name, std::string type, bool hide, bool inverted_b, bool enabled, std::string color, std::string opacity, std::map< std::string, std::string > params, bool last)
Definition: main_controller.cc:622