Lines Matching refs:Graph
1 //===-------------------- Graph.h - PBQP Graph ------------------*- C++ -*-===//
10 // PBQP Graph class.
44 /// PBQP Graph class.
48 class Graph : public GraphBase {
82 void removeAdjEdgeId(Graph &G, NodeId ThisNId, AdjEdgeIdx Idx) {
113 NIds[0] = NIds[1] = Graph::invalidNodeId();
119 void connectToN(Graph &G, EdgeId ThisEdgeId, unsigned NIdx) {
126 void connectTo(Graph &G, EdgeId ThisEdgeId, NodeId NId) {
135 void connect(Graph &G, EdgeId ThisEdgeId) {
149 void disconnectFromN(Graph &G, unsigned NIdx) {
157 void disconnectFrom(Graph &G, NodeId NId) {
238 Graph(const Graph &Other) {}
239 void operator=(const Graph &Other) {}
253 NodeItr(NodeId CurNId, const Graph &G)
279 EdgeItr(EdgeId CurEId, const Graph &G)
305 NodeIdSet(const Graph &G) : G(G) { }
313 const Graph& G;
318 EdgeIdSet(const Graph &G) : G(G) { }
326 const Graph& G;
346 /// @brief Construct an empty PBQP graph.
347 Graph() : Solver(nullptr) {}
349 /// @brief Construct an empty PBQP graph with the given graph metadata.
350 Graph(GraphMetadata Metadata)
353 /// @brief Get a reference to the graph metadata.
356 /// @brief Get a const-reference to the graph metadata.
359 /// @brief Lock this graph to the given solver instance in preparation
361 /// each node in the graph, and handleAddEdge for each edge, to give the
453 /// @brief Returns true if the graph is empty.
461 /// @brief Get the number of nodes in the graph.
462 /// @return Number of nodes in the graph.
465 /// @brief Get the number of edges in the graph.
466 /// @return Number of edges in the graph.
590 /// @brief Remove a node from the graph.
614 /// This does not correspond to any normal graph operation, but exists to
615 /// support efficient PBQP graph-reduction based solvers. It is used to
616 /// 'effectively' remove the unnamed node from the graph while the solver
624 /// A disconnected edge WILL still appear in an iteration over the graph
627 /// A disconnected edge should not be removed from the graph, it should be
658 /// @brief Remove an edge from the graph.
669 /// @brief Remove all nodes and edges from the graph.