You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/// 1\. A custom comparator for the internal priority queue.
48
+
///
49
+
/// 2\. Tracks discovered vertices.
50
+
///
51
+
/// 3\. Injects the comparator to order the search exploration.
52
+
///
53
+
/// 4\. Initializes the priority queue with the starting vertex.
54
+
///
55
+
/// 5\. Predicate evaluated after popping the highest priority vertex.
56
+
///
57
+
/// 6\. The main visit callback. Returning `false` aborts the search.
58
+
///
59
+
/// 7\. Predicate determining if an adjacent vertex should be pushed into the priority queue.
60
+
///
61
+
/// ### Template Parameters
62
+
/// | Parameter | Description |
63
+
/// | :-------- | :--- |
64
+
/// | G | The type of the graph being traversed. |
65
+
/// | PQCompare | The comparator type used to order elements within the internal `std::priority_queue`. |
66
+
/// | InitQueueRangeType | The type of the container providing the initial roots to enqueue. |
67
+
/// | VisitVertexPredicate | Type of the callable deciding if a popped vertex should be processed. |
68
+
/// | VisitCallback | Type of the callable executed when a vertex is officially visited. |
69
+
/// | EnqueueVertexPred | Type of the callable deciding if an adjacent vertex should be pushed to the queue. |
70
+
/// | PreVisitCallback | Type of the callable executed immediately before `VisitCallback`. |
71
+
/// | PostVisitCallback | Type of the callable executed after all adjacent edges are evaluated. |
72
+
///
73
+
/// @param graph The graph to traverse.
74
+
/// @param pq_compare The comparator instance used to determine priority (highest priority is popped first).
75
+
/// @param initial_queue_content A range of initial @ref gl::algorithm::search_node "search nodes" to seed the priority queue.
76
+
/// @param visit_vertex_pred Predicate evaluated immediately after popping a vertex. If it returns `false`, the vertex is skipped (often used for late-rejection in Dijkstra).
77
+
/// @param visit Callback invoked when a vertex is officially visited. If it returns `false`, the entire PFS immediately aborts.
78
+
/// @param enqueue_vertex_pred Predicate evaluated for each outgoing edge. Returns a @ref gl::algorithm::decision "decision":
79
+
/// - `accept` to enqueue,
80
+
/// - `reject` to skip,
81
+
/// - `abort` to terminate the PFS entirely.
82
+
/// @param pre_visit Hook executed immediately before the `visit` callback.
83
+
/// @param post_visit Hook executed after all adjacent edges of the current vertex have been evaluated.
84
+
/// @return `true` if the queue was exhausted naturally, `false` if the search was aborted early by a callback or predicate.
0 commit comments