浏览代码

doc: updated scheduler doc

Michele Caini 2 年之前
父节点
当前提交
6e03ca088e
共有 2 个文件被更改,包括 8 次插入8 次删除
  1. 2 2
      docs/md/process.md
  2. 6 6
      src/entt/process/scheduler.hpp

+ 2 - 2
docs/md/process.md

@@ -177,8 +177,8 @@ To attach a process to a scheduler there are mainly two ways:
   scheduler.attach([](auto...){ /* ... */ });
   ```
 
-In both cases, the return value is an opaque object that offers a `then` member
-function used to create chains of processes to run sequentially.<br/>
+In both cases, the scheduler is returned and its `then` member function can be
+used to create chains of processes to run sequentially.<br/>
 As a minimal example of use:
 
 ```cpp

+ 6 - 6
src/entt/process/scheduler.hpp

@@ -133,9 +133,9 @@ public:
     /**
      * @brief Schedules a process for the next tick.
      *
-     * Returned value is an opaque object that can be used to attach a child to
-     * the given process. The child is automatically scheduled when the process
-     * terminates and only if the process returns with success.
+     * Returned value can be used to attach a continuation for the last process.
+     * The continutation is scheduled automatically when the process terminates
+     * and only if the process returns with success.
      *
      * Example of use (pseudocode):
      *
@@ -190,9 +190,9 @@ public:
      * void();
      * @endcode
      *
-     * Returned value is an opaque object that can be used to attach a child to
-     * the given process. The child is automatically scheduled when the process
-     * terminates and only if the process returns with success.
+     * Returned value can be used to attach a continuation for the last process.
+     * The continutation is scheduled automatically when the process terminates
+     * and only if the process returns with success.
      *
      * Example of use (pseudocode):
      *