Skip to content

SocketServer

Clément Hamada edited this page Mar 31, 2021 · 4 revisions

The SocketServer listens on a specified address and accepts incoming connections, mapping them according to their file-descriptor, using the SocketConnection returned by the implementation of the onConnection event.

Events

Events are triggered in response to SocketConnection activity.

onConnection

This event is fired on each new accepted connection. The implementation shall return a pointer to a SocketConnection instance that describes the new connection.

onDisconnection

This event is fired on each disconnection. The implementation shall remove references accordingly.

onMessage

This event is fired when data has been received.

Clone this wiki locally