multiple operation queues for an operation
[oweals/gnunet.git] / src / testbed / testbed_api_operations.h
index 519c68139619b60b198ed347a2df428d4eee3b5c..e78ed0fcc1324a11043acbe25f47ebf24d59f204 100644 (file)
@@ -59,13 +59,10 @@ GNUNET_TESTBED_operation_queue_destroy_ (struct OperationQueue *queue);
 
 
 /**
- * Add an operation to a queue.  An operation can be in multiple
- * queues at once.  Once all queues permit the operation to become
- * active, the operation will be activated.  The actual activation
- * will occur in a separate task (thus allowing multiple queue
- * insertions to be made without having the first one instantly
- * trigger the operation if the first queue has sufficient
- * resources).
+ * Add an operation to a queue.  An operation can be in multiple queues at
+ * once. Once the operation is inserted into all the queues
+ * GNUNET_TESTBED_operation_begin_wait_() has to be called to actually start
+ * waiting for the operation to become active.
  *
  * @param queue queue to add the operation to
  * @param operation operation to add to the queue
@@ -76,6 +73,20 @@ GNUNET_TESTBED_operation_queue_insert_ (struct OperationQueue *queue,
                                         *operation);
 
 
+/**
+ * Marks the given operation as waiting on the queues.  Once all queues permit
+ * the operation to become active, the operation will be activated.  The actual
+ * activation will occur in a separate task (thus allowing multiple queue
+ * insertions to be made without having the first one instantly trigger the
+ * operation if the first queue has sufficient resources).
+ *
+ * @param operation the operation to marks as waiting
+ */
+void
+GNUNET_TESTBED_operation_begin_wait_ (struct GNUNET_TESTBED_Operation
+                                     *operation);
+
+
 /**
  * Remove an operation from a queue.  This can be because the
  * oeration was active and has completed (and the resources have