aboutsummaryrefslogtreecommitdiff
path: root/src/testbed/testbed_api.h
diff options
context:
space:
mode:
authorSree Harsha Totakura <totakura@in.tum.de>2013-01-02 09:30:42 +0000
committerSree Harsha Totakura <totakura@in.tum.de>2013-01-02 09:30:42 +0000
commit12125a5027fffe8fccf873b46c08f2c8cb1b96c6 (patch)
tree86c135671af5c9701674bc6f67a953969272d637 /src/testbed/testbed_api.h
parent01e21ba6afe2d16ba45b5a73f2777152fd27ffc3 (diff)
downloadgnunet-12125a5027fffe8fccf873b46c08f2c8cb1b96c6.tar.gz
gnunet-12125a5027fffe8fccf873b46c08f2c8cb1b96c6.zip
- doxygen
Diffstat (limited to 'src/testbed/testbed_api.h')
-rw-r--r--src/testbed/testbed_api.h36
1 files changed, 34 insertions, 2 deletions
diff --git a/src/testbed/testbed_api.h b/src/testbed/testbed_api.h
index 54a622dbf..ed5b38b1d 100644
--- a/src/testbed/testbed_api.h
+++ b/src/testbed/testbed_api.h
@@ -379,9 +379,13 @@ GNUNET_TESTBED_operation_add_ (struct GNUNET_TESTBED_Operation *op);
379 379
380 380
381/** 381/**
382 * Creates a helper initialization message. Only for testing. 382 * Creates a helper initialization message. This function is here because we
383 * want to use this in testing
383 * 384 *
384 * @param cname the ip address of the controlling host 385 * @param trusted_ip the ip address of the controller which will be set as TRUSTED
386 * HOST(all connections form this ip are permitted by the testbed) when
387 * starting testbed controller at host. This can either be a single ip
388 * address or a network address in CIDR notation.
385 * @param hostname the hostname of the destination this message is intended for 389 * @param hostname the hostname of the destination this message is intended for
386 * @param cfg the configuration that has to used to start the testbed service 390 * @param cfg the configuration that has to used to start the testbed service
387 * thru helper 391 * thru helper
@@ -535,10 +539,28 @@ GNUNET_TESTBED_controller_link_ (void *op_cls,
535 *slave_cfg, 539 *slave_cfg,
536 int is_subordinate); 540 int is_subordinate);
537 541
542
543/**
544 * Returns a timing slot which will be exclusively locked
545 *
546 * @param c the controller handle
547 * @param key a pointer which is associated to the returned slot; should not be
548 * NULL. It serves as a key to determine the correct owner of the slot
549 * @return the time slot index in the array of time slots in the controller
550 * handle
551 */
538unsigned int 552unsigned int
539GNUNET_TESTBED_get_tslot_ (struct GNUNET_TESTBED_Controller *c, void *key); 553GNUNET_TESTBED_get_tslot_ (struct GNUNET_TESTBED_Controller *c, void *key);
540 554
541 555
556/**
557 * Function to update a time slot
558 *
559 * @param c the controller handle
560 * @param index the index of the time slot to update
561 * @param key the key to identify ownership of the slot
562 * @param time the new time
563 */
542void 564void
543GNUNET_TESTBED_update_time_slot_ (struct GNUNET_TESTBED_Controller *c, 565GNUNET_TESTBED_update_time_slot_ (struct GNUNET_TESTBED_Controller *c,
544 unsigned int index, 566 unsigned int index,
@@ -546,6 +568,16 @@ GNUNET_TESTBED_update_time_slot_ (struct GNUNET_TESTBED_Controller *c,
546 struct GNUNET_TIME_Relative time); 568 struct GNUNET_TIME_Relative time);
547 569
548 570
571/**
572 * Releases a time slot thus making it available for be used again
573 *
574 * @param c the controller handle
575 * @param index the index of the the time slot
576 * @param key the key to prove ownership of the timeslot
577 * @return GNUNET_YES if the time slot is successfully removed; GNUNET_NO if the
578 * time slot cannot be removed - this could be because of the index
579 * greater than existing number of time slots or `key' being different
580 */
549int 581int
550GNUNET_TESTBED_release_time_slot_ (struct GNUNET_TESTBED_Controller *c, 582GNUNET_TESTBED_release_time_slot_ (struct GNUNET_TESTBED_Controller *c,
551 unsigned int index, 583 unsigned int index,