- * When an established connection is terminated,
- * the OnDisconnect method is triggered.
- */
- virtual int OnDisconnect();
-
- /**
- * When there is data waiting to be read on a
- * socket, the OnDataReady() method is called.
- * Within this method, you *MUST* call the Read()
- * method to read any pending data. At its lowest
- * level, this event is signalled by the core via
- * the socket engine. If you return false from this
- * function, the core removes your socket from its
- * list and erases it from the socket engine, then
- * calls BufferedSocket::Close() and deletes it.
- * @return false to close the socket
- */
- virtual bool OnDataReady();
-
- /**
- * When it is ok to write to the socket, and a
- * write event was requested, this method is
- * triggered.
- *
- * Within this method you should call
- * write() or send() etc, to send data to the
- * other end of the socket.
- *
- * Further write events will not be triggered
- * unless you call WantWrite().
- *
- * The default behaviour of this method is to
- * flush the write buffer, respecting the IO
- * hooking modules.
- *
- * XXX: this used to be virtual, ask us if you need it to be so.
- * @return false to close the socket
- */
- bool OnWriteReady();
-
- /**
- * When an outbound connection fails, and the
- * attempt times out, you will receive this event.
- * The method will trigger once maxtime seconds are
- * reached (as given in the constructor) just
- * before the socket's descriptor is closed.
- * A failed DNS lookup may cause this event if
- * the DNS server is not responding, as well as
- * a failed connect() call, because DNS lookups are
- * nonblocking as implemented by this class.
+ * When an outbound connection fails, and the attempt times out, you
+ * will receive this event. The method will trigger once maxtime
+ * seconds are reached (as given in the constructor) just before the
+ * socket's descriptor is closed. A failed DNS lookup may cause this
+ * event if the DNS server is not responding, as well as a failed
+ * connect() call, because DNS lookups are nonblocking as implemented by
+ * this class.