diff options
Diffstat (limited to 'lampada/scratch')
-rw-r--r-- | lampada/scratch | 90 |
1 files changed, 90 insertions, 0 deletions
diff --git a/lampada/scratch b/lampada/scratch new file mode 100644 index 0000000..e013ded --- /dev/null +++ b/lampada/scratch @@ -0,0 +1,90 @@ +macaw/céu +canopy/sol + +# logic: + +- db +- pending iqs +- ui update sender + + ## logic methods + + - handle_offline: called by lamp + - handle_online: called by lamp + - handle_stanza: called by read thread + + - handle_connect: called by lamp + - handle_disconnect: called by lamp + + - handle_error?: called by lamp handle threads and read thread for error logging + - handle_stream_error: called by supervisor when stream needs to be reset + + +# lamp: + +- login jid (bare or full) +- password provider +- lamp command receiver +- connected session state(connected, supervisorhandle to disconnect current connected session) +- connected state (if intended to be connected or not, for retrying reconnection every minute or something) +- on_crash for connection supervisor +- internal logic struct which has methods to handle logic commands + +# connected: + +- writehandle +- current full jid for connected session + +# supervisor: + +- control_recv +- read_thread_crash +- write_thread_crash +- read_control_handle +- write_control_handle +- on_crash +- connected +- password +- logic + +# read: + +must be passed around when crash +- supervisor_control +- tasks + +can be cloned from supervisor +- connected . +- logic . + +can be recreated by supervisor +- stream +- disconnecting +- disconnect_timedout +- on_crash +- control_recv + +# write: + +must be passed around when crash +- stanza_recv + +can be recreated by supervisor +- stream +- on_crash +- control_recv + + +message types: + +command: + +- getroster +- send message +- etc. + +lamp commands: + +- connect +- disconnect +- command(command) |