Major refactor of network code
authorRyan <ry@tinyclouds.org>
Sat, 2 May 2009 14:34:24 +0000 (16:34 +0200)
committerRyan <ry@tinyclouds.org>
Sat, 2 May 2009 14:34:24 +0000 (16:34 +0200)
commit15d24d8002ae92734a478e592a01234dffd0df2b
tree71c5ff895f190a8fc803b6dd6667126259748b06
parent3886e183fd5f2cf69f84f9829a39e96a905233ec
Major refactor of network code

Here I massively change both the external and internal API of the TCP
sockets and servers.

This change introduces the concept of a protocol object like is found in
Twisted Python. I believe this allows for a much cleaner description of how
a socket behaves. What was once a single object "client" or "connection" is
now represented by two objects: a "connection" and a "protocol".

Well - I don't want to ramble too much because neither API is yet public or
documented.  Look the diff of test/test-pingpong.js to see how things have
changed.
src/net.cc
src/net.h
src/node.cc
test/test-pingpong.js