summaryrefslogtreecommitdiffstats
path: root/src/lib/eina_graph_bfs.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/eina_graph_bfs.h')
-rw-r--r--src/lib/eina_graph_bfs.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/lib/eina_graph_bfs.h b/src/lib/eina_graph_bfs.h
index 77d8b3c..f367cf4 100644
--- a/src/lib/eina_graph_bfs.h
+++ b/src/lib/eina_graph_bfs.h
@@ -39,6 +39,19 @@
typedef struct _Eina_Graph_BFS_Opaque Eina_Graph_BFS;
/**
+ * return the path to reach the given destination from the source.
+ *
+ * @param g the graph to compute the shortest path on.
+ * @param s the source vertex.
+ * @param d the destination vertex.
+ *
+ * @return a list of vertices to follow from source to reach v,
+ * NULL if v is not reachable.
+ */
+EAPI Eina_List *
+eina_graph_bfs_shortest_path(Eina_Graph *g, unsigned int s, unsigned int d);
+
+/**
* returns a Breadth First Search of the given graph.
*
* @param g the graph to build the BFS from.