|
|||
|
|||
|
Inheritance diagram for Notifier:


Public Member Functions | |
| Notifier (InspIRCd *SI) | |
| Notifier (InspIRCd *SI, int newfd, char *ip) | |
| int | GetPort () |
| virtual int | OnIncomingConnection (int newsock, char *ip) |
| If your socket is a listening socket, when a new connection comes in on the socket this method will be called. | |
| virtual bool | OnDataReady () |
| When there is data waiting to be read on a socket, the OnDataReady() method is called. | |
Private Attributes | |
| insp_sockaddr | sock_us |
| socklen_t | uslen |
Definition at line 631 of file m_mysql.cpp.
|
|
Definition at line 643 of file m_mysql.cpp. References sock_us, and uslen. Referenced by OnIncomingConnection(). |
|
||||||||||||||||
|
Definition at line 653 of file m_mysql.cpp. |
|
|
Definition at line 658 of file m_mysql.cpp. References sock_us. Referenced by DispatcherThread(). |
|
|
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.
Reimplemented from BufferedSocket. Definition at line 674 of file m_mysql.cpp. References Connections, GetCharId(), BufferedSocket::Instance, SocketEngine::Recv(), results_mutex, and InspIRCd::SE. |
|
||||||||||||
|
If your socket is a listening socket, when a new connection comes in on the socket this method will be called. Given the new file descriptor in the parameters, and the IP, it is recommended you copy them to a new instance of your socket class, e.g.: MySocket* newsocket = new MySocket(newfd,ip); Once you have done this, you can then associate the new socket with the core using Server::AddSocket(). Reimplemented from BufferedSocket. Definition at line 667 of file m_mysql.cpp. References Notifier(). |
|
|
Definition at line 633 of file m_mysql.cpp. Referenced by GetPort(), and Notifier(). |
|
|
Definition at line 634 of file m_mysql.cpp. Referenced by Notifier(). |