aboutsummaryrefslogtreecommitdiffstats
path: root/doc/PLAN
diff options
context:
space:
mode:
Diffstat (limited to 'doc/PLAN')
-rw-r--r--doc/PLAN19
1 files changed, 19 insertions, 0 deletions
diff --git a/doc/PLAN b/doc/PLAN
new file mode 100644
index 0000000..d3e8778
--- /dev/null
+++ b/doc/PLAN
@@ -0,0 +1,19 @@
+-- Listener Scenario
+create socket, perform bind, set listening
++add read-event listener
++start loop
+
+-- Comm Scenario
+provided socket
+-inside loop
+begin coro
+ read - data not ready
+ yield sock, needRead
+end coro
+coro parent == callback
+(coro parent
+ call coro(sock, event)
+ if not ok, go back.. end
+ if newEvent ~= event then
+ unset event, reset newEvent
+ end) \ No newline at end of file