+enum OperationType
+{
+ START_SEND,
+ STOP_SEND,
+ SET_RATE,
+ SET_PREFERENCE
+};
+
+struct Episode;
+
+struct Experiment;
+
+typedef void (*GNUNET_ATS_TESTING_EpisodeDoneCallback) (
+ struct Episode *e);
+
+typedef void (*GNUNET_ATS_TESTING_ExperimentDoneCallback) (struct Experiment *e,
+ struct GNUNET_TIME_Relative duration,int success);
+
+struct Operation
+{
+ struct Operation *next;
+ struct Operation *prev;
+ long long unsigned int src_id;
+ long long unsigned int dest_id;
+ long long unsigned int value;
+ enum OperationType type;
+};
+
+struct Episode
+{
+ int id;
+ struct Episode *next;
+ struct GNUNET_TIME_Relative duration;
+
+ struct Operation *head;
+ struct Operation *tail;
+};
+
+
+struct Experiment
+{
+ char *name;
+ char *cfg_file;
+ unsigned long long int num_masters;
+ unsigned long long int num_slaves;
+ struct GNUNET_TIME_Relative max_duration;
+ struct GNUNET_TIME_Relative total_duration;
+ struct GNUNET_TIME_Absolute start_time;
+ unsigned int num_episodes;
+ struct Episode *start;
+
+ GNUNET_SCHEDULER_TaskIdentifier experiment_timeout_task;
+ GNUNET_SCHEDULER_TaskIdentifier episode_timeout_task;
+ struct Episode *cur;
+
+ GNUNET_ATS_TESTING_EpisodeDoneCallback ep_done_cb;
+ GNUNET_ATS_TESTING_ExperimentDoneCallback e_done_cb;
+};
+
+/*
+ * Experiment related functions
+ */
+
+
+/**
+ * Execute the specified experiment
+ *
+ * @param e the Experiment
+ * @param ep_done_cb a episode is completed
+ * @param e_done_cb the experiment is completed
+ */
+void
+GNUNET_ATS_TEST_experimentation_run (struct Experiment *e,
+ GNUNET_ATS_TESTING_EpisodeDoneCallback ep_done_cb,
+ GNUNET_ATS_TESTING_ExperimentDoneCallback e_done_cb);
+
+/**
+ * Load an experiment from a file
+ *
+ * @param filename the file
+ * @return the Experiment or NULL on failure
+ */
+struct Experiment *
+GNUNET_ATS_TEST_experimentation_load (char *filename);
+
+
+/**
+ * Stop an experiment
+ *
+ * @param e the experiment
+ */
+void
+GNUNET_ATS_TEST_experimentation_stop (struct Experiment *e);
+
+/*
+ * Traffic related functions
+ */
+
+void
+GNUNET_ATS_TEST_traffic_handle_ping (struct BenchmarkPartner *p);
+
+void
+GNUNET_ATS_TEST_traffic_handle_pong (struct BenchmarkPartner *p);
+