void Visualize(const GraphComponent<Graph>& component, GraphPrinter<Graph> &printer) { printer.open(); printer.AddVertices(component.vertices().begin(), component.vertices().end()); for (auto e_it = component.e_begin(); e_it != component.e_end(); ++e_it) { printer.AddEdge(*e_it); } printer.close(); }
bool Check(const GraphComponent<Graph> & component) const { if (component.v_size() <= min_vertex_number_ || component.v_size() >= max_vertex_number_) return false; for (auto iterator = component.e_begin(); iterator != component.e_end(); ++iterator) { if (this->graph().length(*iterator) <= max_length_) { return true; } } return false; }