Related to #3. Investigate:
- Whether can support them in
TCPSocketIFace directly and automatically in TCPSocket/SSLSocket. For example, as new send and receive method overloads which would return awaitable futures.
- Otherwise try to wrap
TCPSocketIFace into new coroutine-friendly classes like TCPSocketCoro/SSLSocketCoro. These wouldn't have any callbacks or subscriptions on the outside. They would only return awaitable objects which in turn after resume would return the result. The machinery of propagating async responses and errors into await's result would be done under the hood, using the good old TCPSocketSubscription.
All same for the TCPServer.
Related to #3. Investigate:
TCPSocketIFacedirectly and automatically inTCPSocket/SSLSocket. For example, as new send and receive method overloads which would return awaitable futures.TCPSocketIFaceinto new coroutine-friendly classes likeTCPSocketCoro/SSLSocketCoro. These wouldn't have any callbacks or subscriptions on the outside. They would only return awaitable objects which in turn after resume would return the result. The machinery of propagating async responses and errors into await's result would be done under the hood, using the good oldTCPSocketSubscription.All same for the
TCPServer.