aboutsummaryrefslogtreecommitdiff
path: root/src/include/gnunet_testbed_service.h
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2012-09-09 12:30:54 +0000
committerChristian Grothoff <christian@grothoff.org>2012-09-09 12:30:54 +0000
commita1d7926951beb7466a1462e43b9933530e5825f7 (patch)
tree0ae15b2f388a1a9a0a45f95903b2e0b78513c19a /src/include/gnunet_testbed_service.h
parent495ebe5987dbf7562d55e9d6a5751d78ae35ffc2 (diff)
downloadgnunet-a1d7926951beb7466a1462e43b9933530e5825f7.tar.gz
gnunet-a1d7926951beb7466a1462e43b9933530e5825f7.zip
-adding continuation to testbed peer start/stop API
Diffstat (limited to 'src/include/gnunet_testbed_service.h')
-rw-r--r--src/include/gnunet_testbed_service.h23
1 files changed, 21 insertions, 2 deletions
diff --git a/src/include/gnunet_testbed_service.h b/src/include/gnunet_testbed_service.h
index 92a7beb40..ca7230504 100644
--- a/src/include/gnunet_testbed_service.h
+++ b/src/include/gnunet_testbed_service.h
@@ -647,13 +647,28 @@ GNUNET_TESTBED_peer_create (struct GNUNET_TESTBED_Controller *controller,
647 647
648 648
649/** 649/**
650 * Functions of this signature are called when a peer has been successfully
651 * started or stopped.
652 *
653 * @param cls the closure from GNUNET_TESTBED_peer_start/stop()
654 * @param emsg NULL on success; otherwise an error description
655 */
656typedef void (*GNUNET_TESTBED_PeerChurnCallback) (void *cls,
657 const char *emsg);
658
659
660/**
650 * Start the given peer. 661 * Start the given peer.
651 * 662 *
652 * @param peer peer to start 663 * @param peer peer to start
664 * @param pcc function to call upon completion
665 * @param pcc_cls closure for 'pcc'
653 * @return handle to the operation 666 * @return handle to the operation
654 */ 667 */
655struct GNUNET_TESTBED_Operation * 668struct GNUNET_TESTBED_Operation *
656GNUNET_TESTBED_peer_start (struct GNUNET_TESTBED_Peer *peer); 669GNUNET_TESTBED_peer_start (struct GNUNET_TESTBED_Peer *peer,
670 GNUNET_TESTBED_PeerChurnCallback pcc,
671 void *pcc_cls);
657 672
658 673
659/** 674/**
@@ -662,10 +677,14 @@ GNUNET_TESTBED_peer_start (struct GNUNET_TESTBED_Peer *peer);
662 * state of the peer). 677 * state of the peer).
663 * 678 *
664 * @param peer peer to stop 679 * @param peer peer to stop
680 * @param pcc function to call upon completion
681 * @param pcc_cls closure for 'pcc'
665 * @return handle to the operation 682 * @return handle to the operation
666 */ 683 */
667struct GNUNET_TESTBED_Operation * 684struct GNUNET_TESTBED_Operation *
668GNUNET_TESTBED_peer_stop (struct GNUNET_TESTBED_Peer *peer); 685GNUNET_TESTBED_peer_stop (struct GNUNET_TESTBED_Peer *peer,
686 GNUNET_TESTBED_PeerChurnCallback pcc,
687 void *pcc_cls);
669 688
670 689
671/** 690/**