The
RWSocketListener is an abstraction that takes care of many of the details of handling the server side socket. It acts at the Communication Services Layer and acts much like
RWPortal. It can automatically close the socket on destruction and returns
Portal to the connected client. Assuming that
addr is
RWSockAddr, or a derived address type, the following illustrates how you would accept a connection using
RWSocketListener:
The
RWSocketListener class provides a function call operator to accept incoming connections. The function call operator is a simply a convenience and is used elsewhere in the documentation.