Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Implement Exec::wait_any on top of ActivitySet and deprecate one method
[simgrid.git] / include / simgrid / s4u / ActivitySet.hpp
index 8f9e6ed718e4ca9e04f96397bb360b4de0731c6d..86942a3a708d19ed24781e3afa1604ba1a00013f 100644 (file)
 
 #include <vector>
 
-namespace simgrid::s4u {
+namespace simgrid {
+
+extern template class XBT_PUBLIC xbt::Extendable<s4u::ActivitySet>;
+
+namespace s4u {
 /** @brief ActivitiesSet
  *
  * This class is a container of activities, allowing to wait for the completion of any or all activities in the set.
@@ -40,13 +44,12 @@ public:
 
   /** Wait for the completion of all activities in the set, but not longer than the provided timeout
    *
-   * On timeout, an exception is raised, and the completed activities remain in the set. Use test_any() to retrieve
-   * them.
+   * On timeout, an exception is raised.
    *
-   * When no timeout occures, the set is emptied.
+   * In any case, the completed activities remain in the set. Use test_any() to retrieve them.
    */
   void wait_all_for(double timeout);
-  /** Wait for the completion of all activities in the set. The set is emptied afterward. */
+  /** Wait for the completion of all activities in the set. The set is NOT emptied afterward. */
   void wait_all() { wait_all_for(-1); }
   /** Returns the first terminated activity if any, or ActivityPtr(nullptr) if no activity is terminated */
   ActivityPtr test_any();
@@ -77,6 +80,7 @@ public:
   bool has_failed_activities() { return not failed_activities_.empty(); }
 };
 
-}; // namespace simgrid::s4u
+} // namespace s4u
+} // namespace simgrid
 
 #endif