actors: Rename actor-am-i-alive? to actor-alive?.
[8sync.git] / doc / 8sync-new-manual.org
index e85b639b5be2f9a4ef2e0740ac89deabe8ecb5e2..d0a99673891d0482bb522d00370574522f332bb9 100644 (file)
@@ -567,14 +567,14 @@ How about an actor that start sleeping, and keeps sleeping?
                            (loop sleeper-loop))))
 
   (define (sleeper-loop actor message)
-    (while (actor-am-i-alive? actor)
+    (while (actor-alive? actor)
       (display "Zzzzzzzz....\n")
       ;; Sleep for one second
       (8sleep 1)))
 
   (let* ((hive (make-hive))
          (sleeper (hive-create-actor hive <sleeper>)))
-    (ez-run-hive hive (list (bootstrap-message hive sleeper 'loop))))
+    (run-hive hive (list (bootstrap-message hive sleeper 'loop))))
 #+END_SRC
 
 We see some particular things in this example.
@@ -588,7 +588,7 @@ In our sleeper-loop we also see a call to "8sleep".
 "8sleep" is like Guile's "sleep" method, except it is non-blocking
 and will always yield to the scheduler.
 
-Our while loop also checks "actor-am-i-alive?" to see whether or not
+Our while loop also checks "actor-alive?" to see whether or not
 it is still registered.
 In general, if you keep a loop in your actor that regularly yields
 to the scheduler, you should check this.
@@ -645,7 +645,7 @@ reference other actors.
     ""
     (set! (worker-task-left worker) difficulty)
     (display "worker> Whatever you say, boss!\n")
-    (while (and (actor-am-i-alive? worker)
+    (while (and (actor-alive? worker)
                 (> (worker-task-left worker) 0))
       (display "worker> *huff puff*\n")
       (set! (worker-task-left worker)
@@ -664,7 +664,7 @@ Looks like there's nothing left to do but run it:
          (worker (hive-create-actor hive <worker>))
          (manager (hive-create-actor hive <manager>
                                      #:direct-report worker)))
-    (ez-run-hive hive (list (bootstrap-message hive manager 'assign-task 5))))
+    (run-hive hive (list (bootstrap-message hive manager 'assign-task 5))))
 #+END_SRC
 
 #+BEGIN_SRC text
@@ -715,7 +715,7 @@ into a micromanager.
       (if still-working
           (begin (display "manager> Harumph!\n")
                  (8sleep 1)
-                 (when (actor-am-i-alive? manager)
+                 (when (actor-alive? manager)
                    (manager-micromanage-loop manager)))
           (begin (display "manager> Oh!  I guess you can go home then.\n")
                  (<- manager (manager-direct-report manager) 'go-home)))))
@@ -769,11 +769,11 @@ This does what you might expect: it removes the actor from the hive.
 No new messages will be sent to it.
 Ka-poof!
 
-** Extended example: an IRC bot battle
-
-** Adding a "rankings" web page
-
 ** Writing our own <irc-bot> from scratch
 
 * API reference
 
+* Systems reference
+** IRC
+** Web / HTTP
+** COMMENT Websockets