/*
This file is part of GNUnet
- (C) 2008--2012 Christian Grothoff (and other contributing authors)
+ (C) 2008--2013 Christian Grothoff (and other contributing authors)
GNUnet is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published
/**
* @file testbed/testbed_api_topology.h
* @brief header for intra library exported functions
- * @author Sree Harsha Totakura <sreeharsha@totakura.in>
+ * @author Sree Harsha Totakura <sreeharsha@totakura.in>
*/
#ifndef TESTBED_API_TOPOLOGY_H
* fresh. The caller should free it. Can be NULL.
*/
unsigned int
-GNUNET_TESTBED_2dtorus_calc_links (unsigned int num_peers,
- unsigned int *rows,
+GNUNET_TESTBED_2dtorus_calc_links (unsigned int num_peers, unsigned int *rows,
unsigned int **rows_len);
-#endif
-/* end of testbed_api_topology.h */
+/**
+ * Get a topology from a string input.
+ *
+ * @param topology where to write the retrieved topology
+ * @param topology_string The string to attempt to
+ * get a configuration value from
+ * @return GNUNET_YES if topology string matched a
+ * known topology, GNUNET_NO if not
+ */
+int
+GNUNET_TESTBED_topology_get_ (enum GNUNET_TESTBED_TopologyOption *topology,
+ const char *topology_string);
+
+
+/**
+ * Returns the string corresponding to the given topology
+ *
+ * @param topology the topology
+ * @return the string (freshly allocated) of given topology; NULL if topology cannot be
+ * expressed as a string
+ */
+char *
+GNUNET_TESTBED_topology_to_str_ (enum GNUNET_TESTBED_TopologyOption topology);
+
+#endif
+/* end of testbed_api_topology.h */